Skip to content

Instantly share code, notes, and snippets.

@rebane2001
Created February 12, 2025 14:27
Show Gist options
  • Save rebane2001/252299992e9bdb9c7b664e7e191b8cef to your computer and use it in GitHub Desktop.
Save rebane2001/252299992e9bdb9c7b664e7e191b8cef to your computer and use it in GitHub Desktop.
278 characters (to fit in tweet), made for fun ^_^ sadly not perfect >_> i could've saved a character by rearranging the for loop but i wanted it to have my fun nicknames (lyra, leera, lea...)
I=Math;P=I.PI*2;t=c.getContext`2d`;l=(S,_)=>t.moveTo(..._)*[0,64].map(T=>t.arc(...S,T,0,P))*t.stroke();B=O=>[I.cos,I.sin].map(H=>H(O*P/6)*128);r=_=>_.map(x=>x+x);t.translate(384,384);i=6;while(i--)for(j=6;j;j--){y=B(i);e=r(y);a=B(j);l(y,r(a))/l(e,r(a))/l(e,a)/l(y,a)/l([0,0],a)}
<canvas id=c width=777 height=777><script>I=Math;P=I.PI*2;t=c.getContext`2d`;l=(S,_)=>t.moveTo(..._)*[0,64].map(T=>t.arc(...S,T,0,P))*t.stroke();B=O=>[I.cos,I.sin].map(H=>H(O*P/6)*128);r=_=>_.map(x=>x+x);t.translate(384,384);i=6;while(i--)for(j=6;j;j--){y=B(i);e=r(y);a=B(j);l(y,r(a))/l(e,r(a))/l(e,a)/l(y,a)/l([0,0],a)}</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment