print "$+{first} $+{last}\n" if m/^ (? [^%]+ ) % (? [^%]+ ) % (? A [^%]+ ) /x; #### print "$2 $1\n" if m/^([^%]+)%([^%]+)%(A[^%]+)/;