What is this? Another version of the well known ... def what(n): x,y = range(n), [0]*n x[1]= 0 z = 0 while z*z <= n: z+=1 if x[z]: x[z*z:n:z]=y[z*z:n:z] return [z for z in x if z] Regards, Gregor (*) at least in good old Europe