On Thu, Mar 20, 2008 at 12:05 PM, Sharan Basappa <[EMAIL PROTECTED]> wrote: > ok. thats what I wanted to confirm. I my crude code, I was doing > exactly that and was > wondering if there is some other way to make an entry without really > adding value. > Maybe, perl has to do it internally but will be much more optimal than the > one > I am simply forcing a value of 1 snip
Not in Core Perl, but you could always write a hash set implementation in C, write some XS code to expose its functions to Perl, and then use tie* to tie the result to a hash: tie my %hashset, "Your::HashSet", @list; * http://perldoc.perl.org/functions/tie.html -- Chas. Owens wonkden.net The most important skill a programmer can have is the ability to read. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/