summaryrefslogtreecommitdiffhomepage
path: root/ruby.html.markdown
diff options
context:
space:
mode:
authorKaleb Davis <kalebdavisgithub@gmail.com>2015-10-06 20:55:51 -0400
committerKaleb Davis <kalebdavisgithub@gmail.com>2015-10-06 20:55:51 -0400
commitf165e721cedf80edf560304b7d83b0687045f8b1 (patch)
treeef6aacb88701d41b1dac14529a5cc2eb7419e722 /ruby.html.markdown
parent6ac7368b3b8e3ce1ee6c50c9f088553e7cbc6d1a (diff)
Update ruby.html.markdown
Diffstat (limited to 'ruby.html.markdown')
-rw-r--r--ruby.html.markdown8
1 files changed, 7 insertions, 1 deletions
diff --git a/ruby.html.markdown b/ruby.html.markdown
index 8f23b2e6..3e85a038 100644
--- a/ruby.html.markdown
+++ b/ruby.html.markdown
@@ -106,8 +106,14 @@ placeholder = 'use string interpolation'
'hello ' + 3 #=> TypeError: can't convert Fixnum into String
'hello ' + 3.to_s #=> "hello 3"
-# print to the output
+# print to the output with a newline at the end
puts "I'm printing!"
+#=> I'm printing!
+#=> nil
+
+# print to the output without a newline
+print "I'm printing!"
+#=> I'm printing! => nill
# Variables
x = 25 #=> 25