Skip to content

Instantly share code, notes, and snippets.

@RobertCam
Created September 29, 2015 22:49
Show Gist options
  • Save RobertCam/93cbf73ccf708417e3ca to your computer and use it in GitHub Desktop.
Save RobertCam/93cbf73ccf708417e3ca to your computer and use it in GitHub Desktop.
Shakil the Dawg
puts "Shakil is barking, what will you do?"
answer = gets.chomp
while (answer != "go away") do
puts "what next?"
answer = gets.chomp
if answer == "woof"
puts "WOOF WOOF WOOF!"
elsif answer == "shakil stop"
puts "he stopped barking, good job dog whisperer"
elsif answer == "Shakil STOP!"
puts "he stopped barking, good job dog whisperer"
elsif answer == "meow"
puts "woof woof woof woof woof"
elsif answer.include? "treat"
puts "Shakil stopped barking. But now he wants a treat"
if answer == "go away"
puts "good-bye"
break
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment