@anonymous/

PolishedFragrantSpidermonkey

Ruby

No description

fork
loading
Files
  • main.rb

This Plugin Crashed!

Error: Error: must not create an existing file {"type":"CREATE_FILE","wid":"0.8788669164010932","path":"main.rb","file":{"path":"main.rb","content":{"asEncoding":{"base64":"ZGVmIGYobixrPW4paz4wPyhmKG4say0xKStmKG4rMSxrLTEpKS8yOm48MD8wOmYobi0xLDApKygtMSkqKm4vKDIqbisxLjApZW5kO2ZvciBuIGluIDEuLjI1ZG8gcCA0KmYobillbmQ="},"asBuffer":null},"loaded":true}}
1
def f(n,k=n)k>0?(f(n,k-1)+f(n+1,k-1))/2:n<0?0:f(n-1,0)+(-1)**n/(2*n+1.0)end;for n in 1..25do p 4*f(n)end
ruby 2.5.5p157 (2019-03-15 revision 67260) [x86_64-linux]