Составьте программу вычисления значения переменной по заданной расчетной формуле и набором исходных данных y=sin(x^2+a)-корень x/b a=1.1 z = x^2/a+cos(x+b)^3 x=0.2 b=0.004
' Basic консольное Dim x As Double, y As Double, z As Double, a As Double, b As Double a = 1.1 x = 0.2 b = 0.004 z = sin((x * x) + a) - sqr(x / b) y = (x * x) / a + cos(x + b) ^ 3 Print "z = "; z Print "y = "; y
' Visual Basic 2015 с формами Dim x As Double, y As Double, z As Double, a As Double, b As Double a = 1.1 x = 0.2 b = 0.004 z = Math.Sin((x * x) + a) - Math.Sqrt(x / b) y = (x * x) / a + Math.Cos(x + b) ^ 3 Label1.Text = "z = " + z.ToString Label2.Text = "y = " + y.ToString
var (a,x,b):=ReadInteger3('Введите a,x,b');
Println('Y=',sin(abs(x)+a)-sqrt(x/b));
Println('Z=', abs(x)/a+abs(cos(x+b))*cos(x+b));
end.
P. S Написано на PacalABC. NET, проверьте на работо писал без компилятора.
Dim x As Double, y As Double, z As Double, a As Double, b As Double
a = 1.1
x = 0.2
b = 0.004
z = sin((x * x) + a) - sqr(x / b)
y = (x * x) / a + cos(x + b) ^ 3
Print "z = "; z
Print "y = "; y
' Visual Basic 2015 с формами
Dim x As Double, y As Double, z As Double, a As Double, b As Double
a = 1.1
x = 0.2
b = 0.004
z = Math.Sin((x * x) + a) - Math.Sqrt(x / b)
y = (x * x) / a + Math.Cos(x + b) ^ 3
Label1.Text = "z = " + z.ToString
Label2.Text = "y = " + y.ToString