from math import*
#1
y, t = float(input("y=")), float(input("t="))
S = (4.351 * y**3 + 2*t + log(t)) / sqrt(cos(2*y) + 4.351)
print("S =", S)
#2
a, b, x = float(input("a=")), float(input("b=")), float(input("x="))
y, r, K = float(input("y=")), float(input("r=")), float(input("K="))
D = (pow(K, -a*r*x) - a * sqrt(6) - cos(3*a*b)) / ((sin(a*asin(x) + log(y)))**2)
print("D = ", D)