| untitled.gif welcome towards my cool internet house site: posting |
welcome to my cool internet home sit
is prosecÇ–tedt to a jam
Hair Cares Product!!!!!
| re: dear prof tobot |
| [29745] by "max cooking"
(ce-web1.wesleyan.edu) on Wed 10 Dec 2003 01:27:40
[
reply ]
|
yea nevermind my other annoyance questions sry!!!!!
i am the win again:
twinprime (test whether x is a lower twin prime)
fun twinprime 0 = false
| twinprime 1 = false
| twinprime x =
if (prime x) andalso (prime (x+2))
then true
else false
TWINPRIMELIST (a list of twin primes <= x)
fun twinprimelist 0 = []
| twinprimelist x =
if twinprime x
then x :: x+2 :: (twinprimelist (x-1))
else (twinprimelist (x-1));
now i will get my lazy counterpartners 2 make the "perfect number" (i.e. number whose factors added up = the number like 6 (1+2+3=6 and 1*2*3=6) list program!! |
: post your reply here :
|