#!/usr/bin/perl $a=shift;while((print$_=$a,"\n")&&/../){$a="";while(s/(.)(.)/$2/e){$b=$1+$2;$a.=$b%10+int($b/10);}}