while True: for i int ["/","-","\\","|"]: print "%s\r" % i,
print "abcd", print "efg", print "h","i"
print "abcd"+"efg"
print "abcd\re"
import time while True: for i in ["/","-","\\","|"]: print "%s\r" % i, time.sleep(0.2)
import sys,time while True: for i in ["/","-","\\","|"]: print "%s\r" % i, sys.stdout.flush() time.sleep(0.2)
原文:http://www.cnblogs.com/zhengyue/p/5071583.html