Sebastian Bassi wrote: > On 8/15/07, Mikael Olofsson <[EMAIL PROTECTED]> wrote: > >> What is unclear here is in what order the keys should be visited. The >> following assumes that the keys should be considered in alphanumeric order. >> > > Yes, my fault. The orden should be given by a string, like: > > DCDBA > Using this dictionay. > A={'A':['1','2'],'B':['4','5'],'C':['6','7','8'],'D':['9']} > > Should return: > > '96941' > '97941' > '97942' > '96942' > '98941' > '98942' > '96951' > '97951' > '97952' > '96952' > '98951' > '98952'
OK, seems like you need to add a second argument to the function specifying this order. I leave that to you. /MiO -- http://mail.python.org/mailman/listinfo/python-list