printing - Python stdin request coming before stdout prints -
i've been trying learn python 3.3 , run problem. here test code using:
print('should print before stdin') x = raw_input('enter something: ')
and here output looks like:
>>something should print before stdin enter something:
why print statements coming after stdin?
in python 3.x, raw_input("")
has been eliminated , use input()
instead. refer docs.
print('should print before stdin') x = input('enter something: ')
output
should print before stdin enter something: yes process finished exit code 0
Comments
Post a Comment