Show More
@@ -17,10 +17,10 b' def pyfunc():' | |||
|
17 | 17 | 5 |
|
18 | 18 | |
|
19 | 19 | >>> for i in range(3): |
|
20 |
... print |
|
|
21 |
... print |
|
|
20 | ... print(i, end=' ') | |
|
21 | ... print(i+1, end=' ') | |
|
22 | 22 | ... |
|
23 | 0 1 1 2 2 3 | |
|
23 | 0 1 1 2 2 3 | |
|
24 | 24 | """ |
|
25 | 25 | return 'pyfunc' |
|
26 | 26 | |
@@ -34,10 +34,10 b' def ipfunc():' | |||
|
34 | 34 | Out[3]: 5 |
|
35 | 35 | |
|
36 | 36 | In [26]: for i in range(3): |
|
37 |
....: print |
|
|
38 |
....: print |
|
|
37 | ....: print(i, end=' ') | |
|
38 | ....: print(i+1, end=' ') | |
|
39 | 39 | ....: |
|
40 | 0 1 1 2 2 3 | |
|
40 | 0 1 1 2 2 3 | |
|
41 | 41 | |
|
42 | 42 | |
|
43 | 43 | Examples that access the operating system work: |
@@ -59,7 +59,7 b' def ipfunc():' | |||
|
59 | 59 | In [7]: 'hi' |
|
60 | 60 | Out[7]: 'hi' |
|
61 | 61 | |
|
62 |
In [8]: print |
|
|
62 | In [8]: print(repr(_)) | |
|
63 | 63 | 'hi' |
|
64 | 64 | |
|
65 | 65 | In [7]: 3+4 |
@@ -135,7 +135,7 b' def iprand():' | |||
|
135 | 135 | In [7]: 3+4 |
|
136 | 136 | Out[7]: 7 |
|
137 | 137 | |
|
138 |
In [8]: print |
|
|
138 | In [8]: print('hello') | |
|
139 | 139 | world # random |
|
140 | 140 | |
|
141 | 141 | In [9]: iprand() |
@@ -152,13 +152,10 b' def iprand_all():' | |||
|
152 | 152 | In [7]: 1 |
|
153 | 153 | Out[7]: 99 |
|
154 | 154 | |
|
155 |
In [8]: print |
|
|
155 | In [8]: print('hello') | |
|
156 | 156 | world |
|
157 | 157 | |
|
158 | 158 | In [9]: iprand_all() |
|
159 | 159 | Out[9]: 'junk' |
|
160 | 160 | """ |
|
161 | 161 | return 'iprand_all' |
|
162 | ||
|
163 | ||
|
164 |
General Comments 0
You need to be logged in to leave comments.
Login now