1
0
Fork 0
lrthw/exercises/ex10.rb

20 lines
385 B
Ruby
Raw Normal View History

2023-09-30 13:20:59 +00:00
puts "I am 6'2\" tall." # escape double-quote inside string
puts 'I am 6\'2" tall.' # escape single-quote inside string
tabby_cat = "\tI'm tabbed in."
persian_cat = "I'm split\non a line."
backslash_cat = "I'm \\ a \\ cat."
fat_cat = "
I'll do a list:
\t* Cat food
\t* Fishies
\t* Catnip\n\t* Grass
"
puts tabby_cat
puts persian_cat
puts backslash_cat
puts fat_cat
puts "\x10 bell"