<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>RubyLearning Blog &#187; Geoffrey Grosenbach</title>
	<atom:link href="http://rubylearning.com/blog/author/geoffreygrosenbach/feed/" rel="self" type="application/rss+xml" />
	<link>http://rubylearning.com/blog</link>
	<description>Helping Ruby Programmers become Awesome</description>
	<lastBuildDate>Tue, 21 May 2013 02:40:50 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=</generator>
		<item>
		<title>How to Learn Ruby (or any programming language)</title>
		<link>http://rubylearning.com/blog/2010/09/20/how-to-learn-ruby-or-any-programming-language/</link>
		<comments>http://rubylearning.com/blog/2010/09/20/how-to-learn-ruby-or-any-programming-language/#comments</comments>
		<pubDate>Mon, 20 Sep 2010 01:02:35 +0000</pubDate>
		<dc:creator>Geoffrey Grosenbach</dc:creator>
				<category><![CDATA[Beginners]]></category>
		<category><![CDATA[Ruby]]></category>
		<category><![CDATA[Ruby Masters]]></category>
		<category><![CDATA[Geoffrey Grosenbach]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://rubylearning.com/blog/?p=4566</guid>
		<description><![CDATA[Send to Kindle How to Learn Ruby (or any programming language) This guest post is contributed by Geoffrey Grosenbach, who designs, produces, and publishes the acclaimed PeepCode Screencasts for web developers and alpha geeks. PeepCode publishes cutting edge training videos on jQuery, Git, Ruby on Rails, RSpec, and iPhone development. The first programming language I [...]<p><a href="http://www.launchbit.com/az/113-209/"><img width="468" height="60" src="http://www.launchbit.com/az-images/113-209/" /></a><br />
<small>(Powered by <a href="http://www.launchbit.com/lb/113-209/">LaunchBit</a>)</small></p>
]]></description>
				<content:encoded><![CDATA[<div class='kindleWidget kindleLight' ><img src="http://rubylearning.com/blog/wp-content/plugins/send-to-kindle/media/black-25.png" /><span>Send to Kindle</span></div><p></p>
<div class="topsy_widget_data topsy_theme_brick-red" style="float: right;margin-left: 0.75em; background: url(data:,%7B%20%22url%22%3A%20%22http%253A%252F%252Frubylearning.com%252Fblog%252F2010%252F09%252F20%252Fhow-to-learn-ruby-or-any-programming-language%252F%22%2C%20%22shorturl%22%3A%20%22http%3A%2F%2Fbit.ly%2Fc4kTnP%22%2C%20%22style%22%3A%20%22big%22%2C%20%22title%22%3A%20%22How%20to%20Learn%20Ruby%20%28or%20any%20programming%20language%29%22%20%7D);"></div>
<div>
<h3>How to Learn Ruby (or any programming language)</h3>
<p class="update">This guest post is contributed by <b><a href="https://topfunky.backpackit.com/pub/846300-conference-bio">Geoffrey Grosenbach</a></b>, who designs, produces, and publishes the acclaimed <a href="http://peepcode.com/">PeepCode Screencasts</a> for web developers and alpha geeks. PeepCode publishes cutting edge training videos on jQuery, Git, Ruby on Rails, RSpec, and iPhone development.</p>
<p class="block"><img style=' float: right; padding: 4px; margin: 0 0 2px 7px;'  class="alignright" src="http://rubylearning.com/images/geoffrey_grosenbach.jpg" title="Geoffrey Grosenbach" alt="Geoffrey Grosenbach" /> The first programming language I learned was <span class="caps">BASIC</span>. Not Visual Basic or Real Basic but plain <span class="caps">BASIC</span> &#8211; line numbers, <span class="caps">GOTO</span>, and all.</p>
<p>But it wasn&#8217;t just my first programming language, it was also my first experience at programming, period. We learned from recipe cards that introduced one aspect of the language and then asked us to write a program (which happened to need the keyword or technique that was just introduced).</p>
<p>At the age of 10, I remember staring at some of the cards with absolutely no idea where to begin. I didn&#8217;t have any of the thinking tools that I do now: breaking a problem into smaller parts, rephrasing a problem from the perspective of the user, building a list of expectations.</p>
<p>On the other hand, the problems were small and most could be solved within a single technological epiphany. The best lesson I learned was one I still use everyday: most problems can&#8217;t be solved in a single 5-minute session of thinking (which happened to be the length of my attention span at that time). I&#8217;ve since learned new skills and thought of creative solutions to problems by noodling over them from many angles and sometimes over quite long periods of time. However, an <a href="http://www.devry.edu/degree-programs/college-engineering-information-sciences/computer-information-systems-about.jsp">online information systems degree</a> is still your best option for learning.</p>
<p>Learning Ruby is no different. Here are three angles from which to contemplate Ruby.</p>
<h3>Code</h3>
<p>Now that I&#8217;ve learned the core principles of programming (variables, loops, methods), I start learning any new programming language by comparing the new syntax to other languages that I know.</p>
<p>How are variables set? How do I define and call a method? Do lines of code end in a semicolon or without? The bare basics.</p>
<p>Sometimes I find it easiest to just look at a few pages of existing code and try to figure it out. But this can be dangerous! Things that look familiar may have unexpected nuances. As soon as possible, try out your suspicions by writing a few lines of code to see if it works as you expect. Ruby comes with <code>irb</code> (an interactive console) but saving code in a file makes it easier to refer to later or run again.</p>
<h3>Culture</h3>
<p>After learning what&#8217;s possible, I try to learn how the language is actually used by those who know and love the language.</p>
<p>When I first learned to use the Git source code control system, I was able to do everything I needed. But I soon learned that I was doing it in the wrong way. After talking to someone who uses it every day, I discovered that there were much easier ways to accomplish common tasks.</p>
<p>Ruby developers mostly stick to a similar aesthetic: use underscores for variable and method names, but camel case for class names. Indent with two spaces. Use underscores for file names (even if it contains a class that is camel cased).</p>
<p>Higher-level code strategy gets more complicated. Many Ruby developers prefer the &#8220;no code is faster than no code&#8221; approach. Write code that covers the most likely scenarios (and error conditions) rather than importing libraries with dozens of methods that will never be used.</p>
<p>Others prefer a more full-featured, full stack approach where everything they need is already available in a framework (but may include tens of thousands of lines of unused code).</p>
<p>Understand both philosophies and use the one that&#8217;s most appropriate for the current task. If you know many developers who use Rails, find others who use it rarely and learn from them about other possible ways to organize your code.</p>
<h3>Creativity</h3>
<p>Once I&#8217;ve learned the syntax and culture of an unfamiliar programming language, I test my new knowledge on a fresh project. This is your chance to combine technical knowledge with a fresh perspective in order to produce a creative outcome.</p>
<p>Although most programming languages can accomplish the same tasks, each has its own differences that make some problems easier than others.</p>
<p>Ruby&#8217;s blocks are hard to recreate in Python and are used differently than JavaScript functions. Learn to use <code>yield</code>, <code>call</code>, and the various code evaluation techniques.</p>
<p>Don&#8217;t limit your creativity by the code you see other people write. Have your own ideas. Explore new styles and techniques. This is how advancements in computer science are made.</p>
<h3>Conclusion</h3>
<p>There are many resources available for learning Ruby. But your most important resource is your mind. The approach you take when learning Ruby will affect not only the speed at which you learn, but the ideas you think of and the programs that you write.  If you are serious about learning Ruby or any other programming language, think about obtaining an information technology degree from a college or university.</p>
<p class="alert"><strong><em>Post supported by 1st Easy Limited</em>:</strong> 1st Easy Limited offer <a href="http://www.1steasy.com/ruby-on-rails.htm">UK based Ruby on Rails hosting</a> running on a Phusion Passenger™ and LAMP stack. If you want to get to know us first, or simply want to try out your Rails or Sinatra skills, <a href="http://www.1steasy.com/ruby-on-rails.htm#try">let us arrange a free trial hosting account</a> for you &#8211; friendly technical support from our team is included!</p>
</div>
<p>Technorati Tags: <a href="http://technorati.com/tag/Ruby" rel="tag">Ruby</a>, <a href="http://technorati.com/tag/Programming" rel="tag"> Programming</a>, <a href="http://technorati.com/tag/Geoffrey+Grosenbach" rel="tag"> Geoffrey Grosenbach</a></p>
Posted by <b>Geoffrey Grosenbach</b><p><a href="http://www.launchbit.com/az/113-209/"><img width="468" height="60" src="http://www.launchbit.com/az-images/113-209/" /></a><br />
<small>(Powered by <a href="http://www.launchbit.com/lb/113-209/">LaunchBit</a>)</small></p>

]]></content:encoded>
			<wfw:commentRss>http://rubylearning.com/blog/2010/09/20/how-to-learn-ruby-or-any-programming-language/feed/</wfw:commentRss>
		<slash:comments>34</slash:comments>
		</item>
	</channel>
</rss>
