fork(1) download
  1. #!/usr/bin/perl
  2. for $N (3,5,7,11) {
  3. $p = 1000 * $N;
  4. printf "$N => %d\n", scalar grep{/0/}
  5. split'', `perl -Mbignum=a,$p -le "print sqrt($N)"`;
  6. }
Time limit exceeded #stdin #stdout 5s 25424KB
stdin
Standard input is empty
stdout
3 => 309
5 => 493
7 => 738
11 => 1079