in reply to [CLOSED] Dereference hash into hashes by key

  1. What exactly did you try?
    my ($hash1, $hash2) = map { {$_ => $hash->{$_}} } qw(key1 key2);
    works for me.
  2. How did you check the content of $hash1 and $hash1 afterwards? Perhaps you had it right but didn't see it...

Replies are listed 'Best First'.
Re^2: Dereference hash into hashes by key
by mlodato (Acolyte) on May 22, 2018 at 16:44 UTC
    See above response. Thanks for your help!