Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def peel(vegetable_with_layers)
- swamp = ["WHAT ARE YOU DOING IN MY SWAMP", "THIS IS MY SWAMP", "THERE IS NO OUR", "STOP SINGING"]
- if vegetable_with_layers[0] == 'core'
- # base case: OGRES HAVE LAYERS
- puts "NOW WHY DID YA HAVE TA GO AND MAKE ME ANGRY"
- vegetable_with_layers[0]
- else
- # ORGERS ARE LIKE ONIONS
- puts swamp[rand(3)]
- peel(vegetable_with_layers[0])
- end
- end
- onion = [[[['core']]]]
- peel(onion) #NO
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement