Skip to content

Instantly share code, notes, and snippets.

Created August 1, 2009 19:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save anonymous/159783 to your computer and use it in GitHub Desktop.
Save anonymous/159783 to your computer and use it in GitHub Desktop.
puts "Hello there, what's your name"
name = gets
@name = name
puts "What's your middle name, #{@name}"
mname = gets.chomp
@mname = mname
puts "What's your last namme, #{@name} #{@mname}"
lname = gets.chomp
@lname = lname
puts "Wow, so your name is #{@name} #{mname} #{lname}"
puts "What's your favorite number?"
number = gets.chomp
@number = number
add= 1
@add = add
sum = #{@add} + #{@number}
@sum = sum
puts "If you add 1 to #{@number}, you get (#{@number} + #{@add}), which equals #{@sum}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment