DEV Community

loading...

Discussion on: What’s your alternative solution? Challenge #46

Collapse
easrng profile image
easrng

Golfed:

let getDistance=(x1, y1, x2, y2, r)=>((x2-x1)**2+(y2-y1)**2) < r**2;