#!/perl -w use strict; print"key in your string :"; chomp( my $string_name=); my $low_string = "a"x length($string_name); my $count = 0; while($low_string ne $string_name) { $low_string++; $count++; } print"$string_name is the $count th value starting from $low_string\n";