in reply to hash table with three input files

Hi,
this looks a lot like homework to me, but to give you a hint:
Use a Hash of arrays (HoA) with the cake name as the hash key and push all three prices into an anonymous array referenced by the hash key.

The data structure should then look like:
{ cake_1 => [ 3, 5, x ], cake_2 => [ ... }

Regards,
svenXY