3 karma · joined Jun 2, 2011 (15y ago) · 2 submissions
comment 15y ago · link · parent
The conditional could be placed outside the string and still be a one-liner. It's there mostly for "flow".
I'm specially fond of
"Happy Birthday #{if i is 3 then "dear Robert" else "to You"}" for i in [1..4]