Question #3380

Write a python program to create “my_contacts.txt” file and write into all your friends contact numbers with their names and save that file.

Expert's answer

fcontact = open ("my_contacts.txt", "w")
fcontact.write ("michael 34234234234\n")
fcontact.write ("rahmanan 23453654564\n")
fcontact.write ("budukozel 67854654623\n")
fcontact.close()
LATEST TUTORIALS
APPROVED BY CLIENTS