<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2716.2200" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><STRONG><FONT face="Century Gothic" size=2>I've written many modest
scripts, but this one baffles me. It generates all the prime numbers under
2000. Can anyone explain it to me? </FONT></STRONG></DIV>
<DIV><STRONG><FONT face="Century Gothic" size=2>Thx, Doug.</FONT></STRONG></DIV>
<DIV><STRONG><FONT face="Century Gothic" size=2></FONT></STRONG> </DIV>
<DIV><STRONG><FONT face="Century Gothic" size=2></FONT></STRONG> </DIV>
<DIV><STRONG><FONT face="Century Gothic" size=2><script><BR><!--<BR>for
(i=2; i<=100; i++) { <BR> if
(i%100==0){document.write("<BR>")}; <BR> prime=true; <BR> for
(j=2; j<i; j++) {
<BR> if
(i%j==0){prime=false;break} <BR> };
<BR> if (prime){document.write(i+" ")};
<BR>}<BR>//--><BR></script><BR></FONT></STRONG></DIV></BODY></HTML>