Project Euler Problem 97

//

I wrote a bunch of these but never posted them up, so I'm just uploading them in bulk now. Not much to say about them at this point.

  1. #!/usr/bin/perl -w
  2.  
  3. sub foo {
  4.     my $num = 1;
  5.     for(my $i = 1; $i <= 7830457; $i++) {
  6.         $num = $num * 2 % 10000000000;
  7.     }
  8.     return $num;
  9. }
  10.  
  11. print 28434*foo() % 10000000000;
  12. print "\n";