Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
pabop_e2 [2011-02-15 09:38]
Joakim Forsgren
pabop_e2 [2022-07-18 13:20] (current)
Line 14: Line 14:
 echo "Detta är alla primtal mellan 2 och " . $antal . "\n"; echo "Detta är alla primtal mellan 2 och " . $antal . "\n";
 $i=2; $i=2;
-while ($i <= antal) { +while ($i <= $antal) { 
-  if(isprime(i))+  if(isprime($i)){
      echo $i . "\n";      echo $i . "\n";
   }   }
   $i++;   $i++;
 } }
 +
 </code> </code>