Skip to content
Hello, World
step 1/5

Reading — step 1 of 5

Learn

~1 min readGetting Started

Ruby is dynamic, object-oriented, and famously concise. There's no boilerplate — every line of code does work.

puts "Hello, World!"
puts "Ship That Code"

puts prints its argument followed by a newline. print skips the newline. p is the debug-print — it shows the inspected form (e.g., strings get quotes around them).

Ruby is interpreted (no compile step) and dynamically typed (no annotations). Variables come into existence when you assign to them. Everything is an object — even nil, true, 5, and "hi". You can call methods on all of them.

Discussion

Ask a question, share an insight, or help someone who’s stuck.

Sign in to post a comment or reply.

Loading…