两个类似的脚本在这里显示出非常奇怪的行为。
A)下面的代码抛出一个nil can't be coerced into Fixnum (TypeError):
    score = 0
    ammount = 4
    score += case ammount
      when ammount >= 3; 10
      when ammount < 3; 1
    end
    puts score
B)另一个正在放入1控制台日志。
    score = 0
    ammount = 4
    score += case ammount
      when ammount >= 3; 10
      else 1
    end
    puts score
我希望这两个脚本都能输出10到控制台。我错了吗?为什么?