Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save mesiriak/4fb046d0579b0ef68ae522e4b711e2bc to your computer and use it in GitHub Desktop.
Save mesiriak/4fb046d0579b0ef68ae522e4b711e2bc to your computer and use it in GitHub Desktop.
Codewars. Python
from numpy import*;circleIntersection=lambda a,b,r:r*r*(lambda q:q<1and arccos(q)-q*(1-q*q)**.5)(hypot(*subtract(b,a))/r/2)//.5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment