Skip to content

Instantly share code, notes, and snippets.

@cyberkov
Created December 22, 2014 07:15
Show Gist options
  • Select an option

  • Save cyberkov/a83e4f1dc318bf66e5a8 to your computer and use it in GitHub Desktop.

Select an option

Save cyberkov/a83e4f1dc318bf66e5a8 to your computer and use it in GitHub Desktop.

Revisions

  1. cyberkov created this gist Dec 22, 2014.
    4 changes: 4 additions & 0 deletions advent.rb
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,4 @@
    2.times { print "Advent, " }
    puts "ein Lichtlein brennt."
    a = { 1 => "eins", 2 => "zwei", 3 => "drei", 4 => "vier", 5 => "steht das Christkind vor der Tür" }
    (1..5).each {|x| puts (x != 1 ? "dann ": "Erst ") + a[x] + (x != 5 ? ", " : ".")}