function distance({x: number, y: number}) { return Math.sqrt(x*x + y*y); }