#!/usr/bin/python3 from math import sqrt p=3 while (p<3300): # See if p is prime pprime=True for f in range (3,int(sqrt(p))+1,2): if (p%f==0): pprime=False break; if not pprime: p+=2 continue Mp=(1<
>p) s=(s&Mp)+(s>>p) if (s==Mp): s=0 if (s==0): prime=True else: prime=False if (prime): print(p,Mp) p+=2