Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: Re^4: Tripwire tests and future-proofing

by zby (Vicar)
on May 25, 2004 at 10:03 UTC ( #356154=note: print w/ replies, xml ) Need Help??


in reply to Re^4: Tripwire tests and future-proofing
in thread Tripwire tests and future-proofing

Thanks. And what with the other question?


Comment on Re: Re^4: Tripwire tests and future-proofing
Re^6: Tripwire tests and future-proofing
by adrianh (Chancellor) on May 25, 2004 at 10:41 UTC

    Two questions:

    • How many items are in the hash in the example you gave?
    • Does keys actually returns a list in a scalar context?

    :-)

Re: Re: Re^4: Tripwire tests and future-proofing
by BUU (Prior) on May 25, 2004 at 21:37 UTC
    keys in scalar context returns the number of elements in the resulting list. Whether this is magic in the keys function, or it's returning an "array" instead of a "list", I have no idea.

    >perl -e"%x=qw/foo bar 1 2 3 4 baz bar/; print scalar keys %x" 4

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://356154]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (14)
As of 2015-07-06 18:20 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (80 votes), past polls