Skip to main content
1 of 5
Noodle9
  • 20.3k
  • 3
  • 21
  • 46

C (clang), 71 bytes

float f(a,n,p,r)float a,n,p,r;{for(r=1;p--;)r*=(a-p)/(a-p/n);return r;}

Try it online!

Calculates the given formula. Returns a float.

Noodle9
  • 20.3k
  • 3
  • 21
  • 46