Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Re: Uninitialized warnings trouble

by Anonymous Monk
on Dec 13, 2022 at 16:44 UTC ( [id://11148832]=note: print w/replies, xml ) Need Help??


in reply to Uninitialized warnings trouble

Forgot to mention that my output is the wrong answer, too.

Replies are listed 'Best First'.
Re^2: Uninitialized warnings trouble
by cavac (Parson) on Dec 16, 2022 at 09:25 UTC

    A typical silicon valley program ("fake it until you make it") would solve it like that:

    print "Calculating...\n"; my $endtime = time + 25; my $x; while(time < $endtime) { $x++; # Todo: Implement better algo for wasting CPU cycles } open(my $ifh, '<', 'solution.txt') or die($!); while((my $line = <$ifh>)) { print $line; } close $ifh;

    Sorry, couldn't resist ;-)

    PerlMonks XP is useless? Not anymore: XPD - Do more with your PerlMonks XP

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (6)
As of 2024-04-24 06:51 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found