My Blog is unique to me.
To get a reverse of a line from a file
f = open('word.txt')
while True:
line = f.readline()
if len(line) == 0:
break
print(line)
print line[::-1]
f.close
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment