What am I doing wrong? I am stuck and may not understand the question


(ruby):2: syntax error, unexpected tIDENTIFIER, expecting '}'
movies["three"] = 3
(ruby):4: syntax error, unexpected '}', expecting $end

Replace this line with your code. 
movies = {
    "Training Day" => 7
    movies["three"] = 3
    puts 7 + movies["three"]

puts "So what is his favorite movie?"
puts "The movie pair was added"

answer = gets.chomp

case choice
when "add" 
  puts "Give me a movie title"
  title = gets.chomp
  puts "Please rate the movie"
  rating = gets.chomp
when "update"
  puts "Updated!"
when "display"
  puts "Movies!"
when "delete"
  puts "Deleted!"
  puts "Error!"


Look up the syntax for the statement where your syntax error is, in this case a hash


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.