Объяснение:
1
program Middle;
var
mid, x1,x2,x3 : integer;
begin
write('input x1, x2, x3 ');
readln(x1,x2,x3);
if x1 < x2
then if x1 < x3
then if x2 < x3
then mid := x2
else mid := x3
else mid := x1
else if x1 > x3
then if x2 < x3
then mid := x3
else mid := x2
else mid := x1;
writeln ('Middle is ',mid);
end.
2
program pifagor;
var
Cat1, Cat2, Hyp, Space : real;
begin
write ('Cat1, Cat2 :');
Readln (Cat1, Cat2);
Hyp := sqrt (sqr(Cat1)+sqr(Cat2));
Space := (Cat1 * Cat2)/2;
WriteLn ('By Cat1 =',Cat1:5:2,' and Cat2 = ',Cat2:5:2,' Hyp is: ',Hyp:5:2, ' Space is: ',Space:5:2);
end.
#include <iostream>
#include <fstream>
#include <random>
using namespace std;
int main()
{
ofstream fout("f.txt");
random_device rd;
mt19937 mer(rd());
for(int i = 0 ; i < 10 ; ++i)
fout << mer() << ' ';
fout.close();
ofstream gout("g.txt");
ifstream fin("f.txt");
for (int i = 0 ; i < 10 ; ++i)
{
unsigned int temp;
fin >> temp;
if( temp % 2 == 0 )
gout << temp << ' ';
cout << temp << ' ';
}
fin.close();
gout.close();
}
Відповідь:
Чупапи муняню
Пояснення:
ответ у него правильний