Skip to content

Instantly share code, notes, and snippets.

@Mparaiso
Created September 8, 2013 18:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Mparaiso/6487316 to your computer and use it in GitHub Desktop.
Save Mparaiso/6487316 to your computer and use it in GitHub Desktop.
humblerubybook
# hello word with ruby.
puts "Hello, world, What is your name?"
myname = gets()
result=<<HERE
Well, hello there, #{myname}."
HERE
puts result;
# RUBY STRINGS
puts %q{this is a single quoted string!}
puts %Q;this is a double quoted string and i write it 4 times : #{"\'some string\' " * 4};
puts "This is a double quoted string"
myString=<<HERE
This is my string.
Heredoc and multiline.
Cool hey ?
HERE
puts myString
# RUBY numbers , Fixnum and Bignum
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment