in reply to Bulk hash population order

Update: what was I thinking!

It seems simpler just to omit %bighash from the right-hand side of the assignment:

%bighash = ( 'C' => 'some new value', 'D' => 4 );

Replies are listed 'Best First'.
Re^2: Bulk hash population order
by Fletch (Bishop) on Nov 27, 2007 at 14:01 UTC

    Assigning to a whole hash (%hash = LIST) clobbers the existing contents; what he's trying to do is append and/or overwrite new contents. Your code has now clobbered the rest of the contents of %bighash and it only has those two keys rather than replacing just the old pairs for the keys C and D.