Yahoo Answers is shutting down on May 4th, 2021 (Eastern Time) and beginning April 20th, 2021 (Eastern Time) the Yahoo Answers website will be in read-only mode. There will be no changes to other Yahoo properties or services, or your Yahoo account. You can find more information about the Yahoo Answers shutdown and how to download your data on this help page.
Trending News
Why am i getting an EOF error on this Python?
I've coded this in Python 2:
user1 = "John Smith"
rank1 = "Colonel"
joined1 = "N/A"
user2 = "Jack Smith"
rank2 = "Captain"
joined2 = "Apr 19, 2014"
user3 = "Dexter Smith"
rank3 = "Major"
joined3 = "Apr 21, 2014"
var = raw_input('Please enter the first name of your target: ')
if var == "John Smith":
print "Name: %s" % user1
print "Rank: %s" % rank1
print "Date Joined: %s" % joined1
if var == "Jack Smith":
print "Name: %s" % user2
print "Rank: %s" % rank2
print "Date Joined: %s" % joined2
if var == "Dexter Smith":
print "Name: %s" % user3
print "Rank: %s" % rank3
print "Date Joined: %s" % joined3
When i run it, i get an EOF error.