Created
April 29, 2011 02:54
-
-
Save JonKernPA/947767 to your computer and use it in GitHub Desktop.
Silliness for SomeSheep
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
=begin | |
Without making any comments on the cynical nature... | |
Instead of :: | |
1. list = ("brother","father","family","tribe","neighbouring tribe","regional community","fellow citizens","foreigners") | |
2. | |
3.def politics.of.dark.ages | |
4.n=1 | |
5.while n<length[list] | |
6.PRINT "I hate my $list[n]!" | |
7.PRINT "But I stand with my $list[n] against my $list[n+1]" | |
8.n=n+1 | |
=end | |
# I tried to compact it into Ruby: | |
last = nil | |
["brother","father","family","tribe","neighbouring tribe","regional community","fellow citizens","foreigners"].each_with_index { |curr,i| puts "I hate my #{last} --> But I stand with my #{last} against my #{curr}" unless i == 0; last = curr; } | |
=begin | |
It generates: | |
I hate my brother --> But I stand with my brother against my father | |
I hate my father --> But I stand with my father against my family | |
I hate my family --> But I stand with my family against my tribe | |
I hate my tribe --> But I stand with my tribe against my neighbouring tribe | |
I hate my neighbouring tribe --> But I stand with my neighbouring tribe against my regional community | |
I hate my regional community --> But I stand with my regional community against my fellow citizens | |
I hate my fellow citizens --> But I stand with my fellow citizens against my foreigners | |
=end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment