1
cj1324 2014-07-09 16:36:19 +08:00 ![]() 直接用import sys; sys.stdout ?
|
![]() |
2
pinepara 2014-07-09 16:37:06 +08:00 ![]() |
![]() |
3
Ansen 2014-07-09 16:41:37 +08:00 ![]() 为啥 我这里是按顺序执行的
|
![]() |
4
hhrmatata OP |
![]() |
5
pinepara 2014-07-09 16:43:31 +08:00 ![]() |
![]() |
7
wy315700 2014-07-09 16:46:00 +08:00 ![]() 终端的输出刷新是按行来的,除非手动调用flush
|
![]() |
9
shyrock 2014-07-09 16:47:45 +08:00 ![]() python2.7.6 执行是对的啊。。。
hehe ... finish! [Finished in 5.1s] |
![]() |
10
Ever 2014-07-09 16:49:07 +08:00 ![]() 不用return就是return None
python3可以print(word, end="") python2.7可以from __future__ import print_function后照python3的做 |
![]() |
12
cakegg 2014-07-09 19:38:33 +08:00 ![]() import sys
import time print "hello", stdout_temp = sys.stdout time.sleep(5) sys.stdout = stdout_temp print "finish" 其实像上面这样写就可以了... |
![]() |
13
hhrmatata OP |