The GOTO statement from Perl has been messed up. This block: © for group in interm: © for newcoup in fin: © for k in group.keys(): © if newcoup.has_key(k): © for kk in group.keys(): newcoup[kk]='x'; © break © break © fin.append(group) ©
should be: © goto=False © for group in interm: © for newcoup in fin: © for k in group.keys(): © if newcoup.has_key(k): © newcoup.update(group); © goto=True © break © if (goto): © goto=False © break © else: © fin.append(group) comlete code is at: http://xahlee.org/perl-python/partition_by_equiv.html Xah [EMAIL PROTECTED] http://xahlee.org/PageTwo_dir/more.html -- http://mail.python.org/mailman/listinfo/python-list