my $i = 4; 1 while $i -- && defined chop $string;