Janos Blazi wrote: > a=-1 > while a!="empty": > a=input() > if "a!=empty": <commands> > > this is pseucode of course. The while loop should run until the user > responds to the input prompt by the enter key (and no real input) > > How can I do this? Have I to use raw_input? Yes: def command(s): print "command:", s while 1: a = raw_input() if not a: break command(a) print "finished" -Steve -- Steve Purcell, Pythangelist Get testing at http://pyunit.sourceforge.net/ Any opinions expressed herein are my own and not necessarily those of Yahoo
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4