How to tell the difference between string and list
Wolfram Kraus
kraus at hagen-partner.de
Fri Dec 5 10:09:20 EST 2003
Heyho!
Jan Kokoska wrote:
[...]
>
> But unfortunately in Zope PythonScripts, where I need to use this, one
> is not supposed to use underscore-prefixed methods as I just found out.
In Zope you can use same_type():
same_type(a, '')
same_type(a, [])
(See Zope Book -> Advanced Zope Scripting -> Built-in Functions)
> I figure this is a question general enough to post here (and not on the
> Zope list), any clues?
>
> TIA
>
> Jan Kokoska
>
HTH,
Wolfram
More information about the Python-list
mailing list