in reply to Re: Re: Removing a certain number of hash keys
in thread Removing a certain number of hash keys
Not nearly as efficient as delete @hash{101..105}, but the following looks nice:
Unless you keep a sorted list of keys separately, I don't think you can do much better than that.delete @hash{ grep {/^101$/../^105$/} sort keys %hash };
Updated slightly.
- tye (but my friends call me "Tye")
|
|---|