Python chars compare in if/else -
the goal y or n , different things based on if/elseif/else statement. problem not see y , n proper values. know doing wrong? print 'are happy final crop?' happytest = raw_input('enter y or n: ') if happytest == 'y': happy = false elif happy == 'n': padding == int(raw_input('enter crop padding:')) else: print 'not valid input' you've got 2 problems can see: elif happy == 'n': references undefined variable, happy . meant happytest . padding == int(raw_input('enter crop padding:')) tries compare padding , int(...) . meant assign. change == = .