On Sat, Oct 4, 2008 at 4:03 AM, David <[EMAIL PROTECTED]> wrote: > Dear list, > > one of the exercises in Zelle's book is: > > given > > import string > s1 = "spam" > s2 = "ni!" > > show a Python expression that could construct the following result by > performing string operations on s1 and s2:
Note that most of the functions in the string module are also available as string methods. The string methods are preferred, so string.capitalize(s1) is more idiomatically written as s1.capitalize() Kent _______________________________________________ Tutor maillist - [email protected] http://mail.python.org/mailman/listinfo/tutor
