update: So I only would like to ignore the 'le' keys!!#! /usr/bin/perl $a = { aa => 'b', bb => 'd', le1 => 'sad', le2 => 'ss' } ; ($c->{$_}) = grep { ! /le/, $a->{$_} } keys %$a ; foreach (keys %$c) { print "key=$_ et val=$c->{$_}\n" ; }
In reply to create hash using grep by jeanluca
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |