Hi guys, codeacademy has taught us to run our code in this manner:
original = raw_input("enter a word:") if len(original)>0: print original else: print "empty"
However, when i enter into my downloaded python, it immediately asks me to input the word before I can even key in my "if" statement. Is there anyway for me to delay this until I finish writing my entire code?
As of now, the only way i managed to work over this is by using this code instead:
def original(word): if len(word)>0: print word else: print "empty" original(raw_input("enter a word:"))
Is there anyway I can get python to not execute my whole code until Im done with it? Ive been stuck for an hour reading forums but cant find an answer ):