1)Функция
program fun;
function ch(a,b,k,m : real): real;
var
f,u,v : real;
begin
u:=7*a*a-4*k+sqrt(a*k);
v:=9*b/(b+7*b*m-m*m);
f:=u*u+2*u*v-3*v;
ch:=f;
end;
x,y,b,c : real;
writeln('Введите числа');
read(x,y,b,c);
writeln('F= ',ch(x,y,b,c):0:2);
end.
2)Процедура
procedure ch(a,b,k,m : real);
writeln('F= ',f:0:2);
ch(x,y,b,c)
Copyright © 2024 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
1)Функция
program fun;
function ch(a,b,k,m : real): real;
var
f,u,v : real;
begin
u:=7*a*a-4*k+sqrt(a*k);
v:=9*b/(b+7*b*m-m*m);
f:=u*u+2*u*v-3*v;
ch:=f;
end;
var
x,y,b,c : real;
begin
writeln('Введите числа');
read(x,y,b,c);
writeln('F= ',ch(x,y,b,c):0:2);
end.
2)Процедура
program fun;
procedure ch(a,b,k,m : real);
var
f,u,v : real;
begin
u:=7*a*a-4*k+sqrt(a*k);
v:=9*b/(b+7*b*m-m*m);
f:=u*u+2*u*v-3*v;
writeln('F= ',f:0:2);
end;
var
x,y,b,c : real;
begin
writeln('Введите числа');
read(x,y,b,c);
ch(x,y,b,c)
end.