These are my Pari progs. They're not much,but they do a lot! I'm just keeping them in this file so I don't lose them. I figured this out with trial and error. Pari is at http://pari.math.u-bordeaux.fr/ Power of 2 for(a=1,16,print(2^a)) Primes of Pow2-1 for(a=1,1024,if(isprime(2^a-1)==1,print("2^",a,"-1=",2^a-1))) above to file for(a=1,65536,if(isprime(2^a-1)==1,writetex("File.txt","2^",a,"-1=",2^a-1))) Primes of Pow2+1 for(a=1,16,if(isprime(2^a+1)==1,print("2^",a,"+1=",2^a+1)))