Created
February 20, 2017 18:46
-
-
Save Phoenix23A/7d3224df20198560621e7eaac5752c83 to your computer and use it in GitHub Desktop.
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
p "Hello" | |
def greeting # here we say def to define a method and put the name of our method | |
p "hello" # here’s the code inside our method | |
end # and here we end or close our method | |
def greeting | |
puts "Please enter your name:" | |
name = gets.chomp | |
puts "Hello" + " " + name | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment