Skip to content

Instantly share code, notes, and snippets.

@mlassoff
Last active April 12, 2020 20:44
Show Gist options
  • Save mlassoff/be1be6e5b8ab30298d1ed729e9839cc7 to your computer and use it in GitHub Desktop.
Save mlassoff/be1be6e5b8ab30298d1ed729e9839cc7 to your computer and use it in GitHub Desktop.
Day 8 Activity 001 Solution for Framework's Python Code Camp
entry = ""
out = ""
while entry != "XXX":
name = raw_input("Enter a full name: ")
phone = raw_input("Enter a phone number: ")
email = raw_input("Enter an email address: ")
print("\n")
entry = raw_input("Press enter to add a new entry or XXX to stop")
out += name + ","
out += phone + ","
out += email
out += "\n"
print("Saving Directory: ")
print(out)
fo = open("directory.csv", "w")
fo.write(out)
fo.close()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment