The world could end today
13. April 2010
13. April 2010
#!/usr/bin/perl $secs_per_day = ((24*60)*60); ($curr_secs, $curr_mins, $curr_hours) = (localtime)[0..2]; $curr_total_secs = (($curr_hours*60)*60)+($curr_mins*60)+$curr_secs; $likelyhood = sprintf("%.2f", (($secs_per_day-$curr_total_secs)/$secs_per_day)*100); print "The chances that the world could end today are $likelyhood%\n";