Cómo contar los puntos de hash duplicados en Ruby 1.8.5 (API de Sketchup Ruby)

Necesito contar los duplicados, deben ser 100% idénticos para aumentar mi cuenta, pero no puedo usar nada de Ruby 1.8.5, este código se ejecutará dentro de un complemento en google sketchup

API de Google Sketchup Ruby
puts VERSION
1.8.5

puts RUBY_PLATFORM
i686-darwin8.10.1

product = 'Glass'
x = width
y = length
z = density

product_list = [
                { "product" => 1, "x" => 200, "y" => 100, "z" => 18},
                { "product" => 1, "x" => 200, "y" => 100, "z" => 18},
                { "product" => 1, "x" => 300, "y" => 100, "z" => 18},
                { "product" => 2, "x" => 300, "y" => 100, "z" => 18},
                { "product" => 2, "x" => 100, "y" => 100, "z" => 18},
                { "product" => 2, "x" => 100, "y" => 100, "z" => 18},
                { "product" => 3, "x" => 100, "y" => 100, "z" => 18}
               ];

product_list_result = product_list.count_duplicate();

product_list_result = [
     { "product" => 1, "x" => 200, "y" => 100, "z" => 18, "count" = 2},
     { "product" => 1, "x" => 300, "y" => 100, "z" => 18, "count" = 1},
     { "product" => 2, "x" => 300, "y" => 100, "z" => 18, "count" = 1},
     { "product" => 2, "x" => 100, "y" => 100, "z" => 18, "count" = 2},
     { "product" => 3, "x" => 100, "y" => 100, "z" => 18, "count" = 1}
                      ];

Respuestas a la pregunta(2)

Su respuesta a la pregunta