79151284

Date: 2024-11-02 17:58:11
Score: 1.5
Natty:
Report link
def calc_pi():

num = 3
ans = 0
sign = '+'
for i in range(1,1000000):
    if sign == '+':
        ans += (1/num)
        sign = '-'
        
    else:
        ans -= (1/num)
        sign = '+'

    num += 2

print(4 * (1-ans))
Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Unregistered user (0.5):
  • Low reputation (1):
Posted by: marz