-
-
Save iamnoobkia/0cabc080fc0fa166a0b2 to your computer and use it in GitHub Desktop.
Revisions
-
iamnoobkia revised this gist
Apr 13, 2016 . 2 changed files with 22 additions and 17 deletions.There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,19 @@ def crazy_aunty puts "Hi Sandra! Say hi to deaf Aunty :)" n = 0 while answer = gets.chomp if answer.empty? n+=1 break if n==2 elsif answer == "I love ya, Aunty, but I've got to go." puts "Bye, Sandra!" break elsif answer == answer.downcase puts "HUH?! SPEAK UP, SANDRA" else answer == answer.upcase puts "NO! WE CANT DO THAT!" end end end crazy_aunty This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -1,12 +1,3 @@ def deaf_aunty puts "Hi Sandra! Say hi to deaf Aunty :)" sandra_input = gets.chomp @@ -16,19 +7,14 @@ def deaf_aunty puts "NO, WE CAN'T DO THAT!" sandra_input = gets.chomp else sandra_input == sandra_input.downcase puts "HUH?! SPEAK UP, SANDRA" sandra_input = gets.chomp end end puts "Bye, Sandra!" end deaf_aunty -
iamnoobkia revised this gist
Mar 28, 2016 . 1 changed file with 3 additions and 3 deletions.There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -16,15 +16,15 @@ def deaf_aunty puts "NO, WE CAN'T DO THAT!" sandra_input = gets.chomp elsif sandra_input == sandra_input.downcase puts "HUH?! SPEAK UP, SANDRA" sandra_input = gets.chomp else puts "Bye, Sandra!" sandra_input = gets.chomp break end -
iamnoobkia revised this gist
Mar 28, 2016 . 1 changed file with 31 additions and 11 deletions.There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -1,14 +1,34 @@ # Prompt user for sandra_input # Loop # If input downcase, reply HUH! SPEAK UP, SANDRA!" # If input upcase, reply NO, WE CANT DO THAT! # Loops end when input == "I love you, aunty, but I've got to go" def deaf_aunty puts "Hi Sandra! Say hi to deaf Aunty :)" sandra_input = gets.chomp while sandra_input != "I love you, aunty, but I've got to go." if sandra_input == sandra_input.upcase puts "NO, WE CAN'T DO THAT!" sandra_input = gets.chomp elsif sandra_input == sandra_input.downcase puts "HUH?! SPEAK UP, SANDRA" sandra_input = gets.chomp else puts "Bye, Sandra!" sandra_input = gets.chomp break end end end deaf_aunty -
code-division renamed this gist
Sep 22, 2014 . 1 changed file with 5 additions and 5 deletions.There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -1,14 +1,14 @@ # Save this file to your computer so you can run it # via the command line (Terminal) like so: # $ ruby deaf_aunty.rb # # Your method should wait for user input, which corresponds # to you saying something to your Aunty. # You'll probably want to write other methods, but this # encapsulates the core Aunty logic def deaf_aunty end # Run our method deaf_aunty -
code-division created this gist
Aug 31, 2014 .There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,14 @@ # Save this file to your computer so you can run it # via the command line (Terminal) like so: # $ ruby deaf_grandma.rb # # Your method should wait for user input, which corresponds # to you saying something to your Grandma. # You'll probably want to write other methods, but this # encapsulates the core Grandma logic def deaf_grandma end # Run our method deaf_grandma