On Tue, 2 Jun 2015 10:23 pm, fl wrote: > I don't know whether there is a way to know the length of lines[3].
The same way as to know the length of anything else: len(x) # the length of x len("hello") # the length of "hello" len(lines[3]) # the length of lines[3] > Then, > I can use a -1 step to get the last two digits. Or, you may have much > better ways to do that. Python is really too versatile I feel. Last two digits of a string: mystring = "123456" mystring[-2:] -- Steven -- https://mail.python.org/mailman/listinfo/python-list