Naming twins in Python & Perl