title: syntax error, unexpected keyword_when, expecting $end in ruby code, codecademy, a night at the movies 6/10
body: <p>I am practicing ruby at codecademy.com, I am getting a strange error, but when I see the code it looks correct to me. 
  Following is my code, (you can also see the code and its output live at <a href="http://codepad.org/FAcz8CSy" rel="nofollow"><strong>CodePad</strong></a></p>
  
  <pre><code>movies = {
      'Janwar' =&gt;  4,
      'Tum Bin' =&gt;  3,
      'PK' =&gt; 3
  }
  
  puts "Select your favorite movie"
  puts "type \"add\" to add a movie to the list"
  puts "type \"delete\" to delete a movie"
  puts "type \"display\" to list the movies"
  
  choice = gets.chomp
  
  case choice
  when "add"
      puts "Please say the movie title"
      title = gets.chomp
      puts "What is the rating of the movie"
      rating = gets.
      if  movies[title.to_sym].nil? == true
          movies[title.to_sym] = rating.to_i
      else
          puts "the thing you wanna add is already there"
      end
  when "update"
      puts "Updated!"
  when "display"
      puts "Movies!"
  when "delete"
      puts "Deleted!"
  else
      puts "Error!df"
  end
  </code></pre>
  
  <p>And this is the error message I get,</p>
  
  <pre><code>Line 25: syntax error, unexpected kWHEN, expecting $end
  when "update"
      ^
  </code></pre>
  
  <p>Would someone please run this code at CodePad and see what is the error?</p>
  
  <p>Thank You All in Advance !</p>