> I got this, Lets say if its mystring[n:m] where n may be another > number and m may be another number so how will it work in that case, > so this becomes general and makes more clear > n is the index of the first character and m is the index *beyond* the last character
> Lets say if its mystring[3:8] so how will i evaluate it It will return the characters at indexes 3,4,5,6, and 7. In other words it operates in the same way as the range function. you could get the same set of characters back using for index in range(n,m): print mystring[index] Does that help? Alan G Author of the learn to program web tutor http://www.freenetpages.co.uk/hp/alan.gauld _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor