5 odpowiedzi
+ 3
Sure, can you share your attempt first?
+ 1
#try something like this
for line in file:
print(line[0]+str(len(line.strip())))
0
Ok just a minute
0
file = open("/usercode/files/books.txt", "r")
for line in file:
print(file.read(1) + str(len(line)))
file.close()
0
It is not working