Skip to content

Instantly share code, notes, and snippets.

@nickgrier07
Last active June 8, 2018 13:30
Show Gist options
  • Select an option

  • Save nickgrier07/4206de72e70b33f3d7b6c5cdff868953 to your computer and use it in GitHub Desktop.

Select an option

Save nickgrier07/4206de72e70b33f3d7b6c5cdff868953 to your computer and use it in GitHub Desktop.
from sys import exit
test1 = raw_input("Please enter an integer: ")
test2 = raw_input("Please enter another integer: ")
if (test1.isdigit() and test2.isdigit()) == True:
test1 = int(test1)
test2 = int(test2)
else:
print "You didn't enter an integer, shame on you!"
exit()
print "You've started at " + str(test1) + "."
for i in range(test1, test2, 1):
i = i + 1
if i < test2:
print "Not quite there yet, you're at " + str(i) + "."
elif i == test2:
print "Congrats, you're at " + str(test2) + "."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment