| 1 | initial version |
That seems to work:
R=[(-1,-1),(-1,0),(-1,1),(0,-1),(0,1),(1,-1),(1,0),(1,1)];
N=100;
L=[(n,m) for n in xsrange(2,N) for m in xsrange(n,N)];
v=[(n,m) for (n,m) in L if len([(i,j) for (i,j) in R if gcd(n+i,m+j)==1])==0];
print v
Copyright Sage, 2010. Some rights reserved under creative commons license. Content on this site is licensed under a Creative Commons Attribution Share Alike 3.0 license.