From: Felix Dominguez Date: 2009-11-20T03:16:15+09:00 Subject: Ternary Operator and Arrays Given: ary = Array.new some_hash = {'a' => 1, 'b' => 2, 'c' => 3} another_array = ['a', 'c'] Then: another_array.each do |x| ary << some_hash.has_key?(key) ? ' ' : some_hash[key] end Expected: ary should be [1, ' ', 3] Actual: [true, false, true] Question: Why does that happen? -Felix