 <p>There's a few ways to clean this up in Ruby that I'll demonstrate here:</p> <pre><code>puts 'Hello mate what is thy first name?' name1 = gets.chomp # Inline string interpolation using #{...} inside double quotes puts "Your name is #{name1} eh? What is thy middle name?" name2 = gets.chomp # Interpolating a single string argument using the String#% method puts 'What is your last name then %s?' % name1 name3 = gets.chomp # Interpolating with an expression that includes code puts "Oh! So your full name is #{ [ name1, name2, name3 ].join(' ') }?" puts 'That is lovey!' # Combining the strings and taking their aggregate length puts 'Did you know there are %d letters in your full name?' % [ (name1 + name2 + name3).length ] # Using collect and inject to convert to length, then sum. puts 'Did you know there are %d letters in your full name?' % [ [ name1, name2, name3 ].collect(&amp;:length).inject(:+) ] </code></pre> <p>The <a href="http://ruby-doc.org/core-2.2.0/String.html#method-i-25" rel="nofollow"><code>String#%</code></a> method is a variant of <a href="http://ruby-doc.org/core-2.2.0/Kernel.html#method-i-sprintf" rel="nofollow"><code>sprintf</code></a> that's very convenient for this sort of formatting. It gives you a lot of control over presentation.</p> <p>That last one might look a bit mind-bending but one of the powerful features of Ruby is being able to string together a series of simple transformations into something that does a lot of work.</p> <p>That part would look even more concise if you used an array to store the name instead of three independent variables:</p> <pre><code>name = [ ] name &lt;&lt; gets.chomp name &lt;&lt; gets.chomp name &lt;&lt; gets.chomp # Name components are name[0], name[1], and name[2] # Using collect -&gt; inject name.collect(&amp;:length).inject(:+) # Using join -&gt; length name.join.length </code></pre> <p>It's generally a good idea to organize things in structures that lend themselves to easy manipulation, exchange with other methods, and are easy to persist and restore, such as from a database or a file.</p>