Dim s As Integer,n As integer
Dim t As single,pi As single
s = 1:t = 1:n = 1:pi = 0
Do While Abs(t) > 0.0001
pi = pi + t
n = n + 2
s = -s
t = s / n
Loop
Print pi * 4
Dim s As Integer,n As integer
Dim t As single,pi As single
s = 1:t = 1:n = 1:pi = 0
Do While Abs(t) > 0.0001
pi = pi + t
n = n + 2
s = -s
t = s / n
Loop
Print pi * 4