Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: How's your Perl? (II)

by ambrus (Abbot)
on Jul 22, 2004 at 13:55 UTC ( #376571=note: print w/ replies, xml ) Need Help??


in reply to How's your Perl? (II)

Spoilers:

Update: and here's an answer for 8, although you might take it as cheating as it requires an adittional option on the command line to be set.

Update: you can give the switch in the shebang line too. If you write this to a file and execute it with perl, it works.


Comment on Re: How's your Perl? (II)
Select or Download Code
Re^2: How's your Perl? (II)
by wog (Curate) on Jul 22, 2004 at 19:37 UTC
    You don't need any switches!

    BEGIN{$^P=0x22;sub DB::DB{++$foo==2 and die}}

    (I am pretty sure that is not the official solution, by the way, and it means that 8 does not need to exploit actual bugs.)

    updated: Oops, copied a wrong version initially. One character difference.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://376571]
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: (11)
As of 2014-12-28 03:36 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (178 votes), past polls