Created
May 29, 2012 14:40
-
-
Save meru-akimbo/2828796 to your computer and use it in GitHub Desktop.
B - さかさま辞書
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
chomp($tango_num = <STDIN>); | |
while(<STDIN>){ | |
@w = split(//, $_); | |
@w = reverse(@w); | |
$s = join('', @w); | |
push @list , $s; | |
} | |
@list = sort @list; | |
for(@list){ | |
@w = split(//, $_); | |
@w = reverse(@w); | |
$s = join('', @w); | |
print $s; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment