John J. Lee wrote: > Peter Otten <[EMAIL PROTECTED]> writes: > [...] >> # -*- coding: utf8 -*- >> r""" >>>>> f("äöü".decode("utf8")) >> (u'\xe4\xf6\xfc',) >> """ >> def f(s): >> return (s,) > > Forgive me if this is a stupid question, but: What purpose does > function f serve?
Like the OP's get_inventary_number() it takes a unicode string and returns a tuple of unicode strings. I'ts pointless otherwise. I hoped I had stripped down his code to a point where the analogy was still recognizable. Peter -- http://mail.python.org/mailman/listinfo/python-list