← RoseCode

ROSECODE 319

The biggest square

sinan · Math ·

Consider the squares in x2 + y2 = R2 circle with vertices on lattice points. The one with the biggest area would be (R,0); (0,R); (-R,0); (0,-R). Find the ones with the second biggest if R = 87654321. Answer format: ∑xi,∑yi,area where yi > xi > 0 and are x,y coordinates of the one of the vertices. Example: 2,4,40 if R = 5 There are 2 squares with area = 40: (2,4); (-4,2); (-2,-4); (4,-2) (4,2); (-2,4); (-4,-2); (2,-4) [My timing: <1s]