Questions on 1.6a2's string methods
mjhand at concentric.net
Fri Apr 14 09:32:12 CEST 2000
1. I see that string objects now support (as methods) most of the
functions from the string module. Among these are:
upper, lower, split, strip, find
and surely others. My question is, why is capwords (which seems
to be in the same genre as upper and lower) not a method?
2. Along these same lines, since split() became a method of the
string type, wouldn't it make sense to make join() a method of
the list type?
3. Are the classlike standard types (list, dictionary, and now
string) equipped with a __dict__ attribute? I can see the names
of all functions supported by a user-defined class by saying
className.__dict__.keys(), but I cannot see the list of methods
for the string type (at least not in the same way). Thus my
need to ask silly questions like #1 above (maybe capwords is
there by some other name??)
Please copy me on any response. Thanks!
More information about the Python-list