63 200
Assignments Done
99,3%
Successfully Done
In July 2018

Answer to Question #3393 in Python for mukunda

Question #3393
Write a program to open a text file which contains two strings, i.e. your first name and last name, read those names and concatenate them and print in a text called fullname.txt. (Note concatenating strings example string1 + string2 if they are of two strings)
Expert's answer
fin = open ("twostrings.txt")
firstname, lastname = fin.readline()[:-1], fin.readline()

fout = open ("fullname.txt", "w")
fout.write(firstname + " " + lastname)
fout.close()

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be first!

Leave a comment

Ask Your question

Submit
Privacy policy Terms and Conditions