17 lines
343 B
Python
Executable File
17 lines
343 B
Python
Executable File
print("введите точность и коэффициент")
|
||
from math import atan
|
||
T = int(input())
|
||
x = float(input())
|
||
count = 0
|
||
num = 0
|
||
for i in range(1, T, 2):
|
||
count += 1
|
||
if count%2 == 1:
|
||
num += (x**i)/i
|
||
else:
|
||
num -= (x**i)/i
|
||
|
||
print(atan(x))
|
||
print(f"Число arctng(x) с точностью {T}: {num}")
|
||
|