guujuu
?>

Напишите программу в построение блок схемы найдите s круга если известен радиус r

Информатика

Ответы

Lenuschakova1982316
R = int(input)
res = 3.14 * r ** 2
print(res)
Винников724

1)

program FunctionIFfull;

uses crt;

var

 x, y : real;

begin

 clrscr;

 write('x = ');

 readln(x);

 if x>=1 then y:= sqrt(3*x+4)  

 else  

     if x<=-1 then y:= sqr(x)+4*x  

     else y:=4*sqr(x)-2*x+3;

 writeln('y = ', y:8:2);

 readln;

end.

2)

program FunctionIFshort;

uses crt;

var

 x, y : real;

begin

 clrscr;

 write('x = ');

 readln(x);

 if x>=1 then y:= sqrt(3*x+4);

 if x<=-1 then y:= sqr(x)+4*x;

 if (x>-1) and (x<1) then y:= 4*sqr(x)-2*x+3;

 writeln('y = ', y:8:2);

 readln;

end.

Объяснение:

1. Повна команда розгалуження має вигляд

if < логічний вираз > then <команда 1> else < команда 2 >;

2. Коротка команда розгалуження має вигляд

if <логічний вираз > then <команда 1>;

zanthia94
#include <iostream>
using namespace std;
int main()
{
cout <<"4,4"<<endl;cout <<"4,5"<<endl;cout <<"4,6"<<endl;cout <<"4,7"<<endl;cout <<"4,8"<<endl;cout <<"4,9"<<endl;cout <<"5,0"<<endl;cout <<"5,1"<<endl;cout <<"5,2"<<endl;cout <<"5,3"<<endl;cout <<"5,4"<<endl;cout <<"5,5"<<endl;cout <<"5,6"<<endl;cout <<"5,7"<<endl;cout <<"5,8"<<endl;cout <<"5,9"<<endl;cout <<"6,0"<<endl;cout <<"6,1"<<endl;cout <<"6,2"<<endl;cout <<"6,3"<<endl;cout <<"6,4"<<endl;
}

Ответить на вопрос

Поделитесь своими знаниями, ответьте на вопрос:

Напишите программу в построение блок схемы найдите s круга если известен радиус r
Ваше имя (никнейм)*
Email*
Комментарий*

Популярные вопросы в разделе

dirzhanov683
barabanoveugeny
Ерохин
kamimoza
v-zhigulin1
fox-cab3444
Galinagol559
yda659
yastrik
troian07
ledlenta751
infosmolenskay
Светлана константин
Пайтон!почему подчёркивает:elif select == '3':​
mansur071199486
Darialaza