Skip to main content
3 votes

Simulate Alpha Decay

Backhand, 99 bytes IIIIII222---$$$444---:::111LLL)))rrr:::111LLL(((***!!!'''BBB***666+++jjj:::111LLL]]]333***sss$$$hhh Attempt This Online! Backhand is a language ...
emanresu A's user avatar
  • 38.7k
3 votes

Complex Exponentiation

JavaScript (ES7), 94 bytes Returns [real, img]. This is essentially the formula used by doubleunary, except I'm computing \$\sqrt{a^2+b^2}\$ (with ...
Arnauld's user avatar
  • 193k
3 votes

Complex Exponentiation

Google Sheets, 91 bytes =let(s,A1^2+B1^2,a,atan2(A1,B1),r,s^(C1/2)/exp(D1*a),u,C1*a+D1*ln(s)/2,{r*cos(u),r*sin(u)}) Put the four coefficients in cells ...
doubleunary's user avatar
  • 1,705
2 votes

Complex Exponentiation

APL (Dyalog Unicode), 87 71 bytes Anonymous infix lambda taking [a,b] as left argument, [c,d] as right argument, and returning <...
Adám's user avatar
  • 30.4k
1 vote

Complex Exponentiation

Google Sheets, 87 bytes Expects \$a\$, \$b\$, \$c\$, \$d\$ in \$A1\$, \$B1\$, \$C1\$, \$D1\$ respectively and it returns the result in two horizontally adjacent cells. ...
z..'s user avatar
  • 741
1 vote

Distance between two points in n-dimensional space

Go, 97 bytes import."math" func f(p,q[]float64)(d float64){for i:=range p{d+=Pow(p[i]-q[i],2)} return Sqrt(d)} Attempt This Online!
bigyihsuan's user avatar
  • 9,696

Only top scored, non community-wiki answers of a minimum length are eligible