Skip to content

Instantly share code, notes, and snippets.

@Shinpeim
Created April 12, 2012 17:48
Show Gist options
  • Save Shinpeim/2369596 to your computer and use it in GitHub Desktop.
Save Shinpeim/2369596 to your computer and use it in GitHub Desktop.
a b c d e f g h i のうちどれかが肉まん
あんまんであることが確定したものは "." と表記する
if ([a b c] == [d e f])
". . . . . . g h i"
if (g == h)
". . . . . . . . i"
else
". . . . . . g h ."
if (g == .)
". . . . . . . h ."
else
". . . . . . g . ."
elsif ([a b c] > [d e f]) ... (1)
"a b c d e f . . ."
if ([a b d] == [. . .])
". . c . e f . . ."
if ([c e] == [. .])
". . . . . f . . ."
elsif ([c e] > [. .]) ... (2)
(1) (2) より、". . c . . . . . ."
els ([c e] < [. .]) ... (3)
(1) (3) より、". . . . e . . . ."
elsif([a b d] > [. . .])
# 上記と同様の手順
else ([a b d] < [c . .])
#上記と同様の手順
else
#上記と同様の手順
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment