aysemustafazade
05.05.2021 08:07

Slim tone: -boost skin health and remove tumor cells slim tone has a proven track record. worrying pertaining to that is the first thing you should do. that's how to tell if slim tone is working as though having a lot of slim tone can force people to narrow their view. ironically, "ask me no questions and i'll tell you no lies." slim tone is certain to be flipped on its head by then. slim tone might go either way. i thought they were asking me to take responsibility for slim tone. it is how to take care of problems with slim tone. click here for more info.> > > >

Нажмите на рекламу ниже и сразу увидите ответ
↓
Популярные вопросы:
Ответ:
ggggeorgiyggg
31.01.2021 12:08
Const 
n=5;

Var
 ar:array[1..n] of integer;
 ar2:array[1..n] of integer;
 i,k:integer;

 function prost(a:integer):boolean;
 var i:integer;
 b:boolean;
  begin
  b:=true;
   for i:=2 to a div 2 do
    if a mod i=0 then
     begin;
      b:=false;
      break;
     end;
   if a=1 then b:=false;
  prost:=b;
 end;

  begin;
 randomize;
 k:=0;
  for i:=1 to n do
   begin;
    ar[i]:=random(101);
    write(ar[i]:4);
   end;
  writeln;
  for i:=1 to n do
  if prost(ar[i]) then
   begin;
    inc(k);
    ar2[k]:=ar[i];
    write(ar2[k]:4);
   end;
end.
0,0(0 оценок)
Ответ:
majten
04.10.2021 22:45
Чтобы квадрат вписался в круг, его диагональ должна быть равна диаметру круга. Если трактовать "уместиться" как "пролезть", то диагональ должна быть меньше диаметра..
Формулы площадей квадрата  S₁ и круга S₂ известны, что легко позволяет нам найти нужное условие.
\displaystyle S_1=a^2 \to a=\sqrt{S_1}; \ d=a \sqrt{2}= \sqrt{2S_1} \\ S_2=\frac{\pi D^2}{4} \to D=\sqrt{\frac{4S_2}{\pi}}; \\ d\ \textless \ D \to \sqrt{2S_1}\ \textless \ \sqrt{\frac{4S_2}{\pi}}; \ 2S_1\ \textless \ \frac{4S_2}{\pi} \ \to \ \boxed{\pi s_1\ \textless \ 2S_2}
Если нужно, чтобы случай, когда квадрат вписан в круг тоже учитывался, строгое неравенство следует заменить нестрогим.

// PascalABC.NET 3.0, сборка 1160 от 05.02.2016
begin
  var s1:=ReadReal('Площадь квадрата');
  var s2:=ReadReal('Площадь круга');
  if pi*s1<2*s2 then Writeln('Квадрат умещается в круге')
  else Writeln('Квадрат не умещается в круге')
end.

Тестовое решение:
Площадь квадрата 24.6
Площадь круга 28.4
Квадрат не умещается в круге
0,0(0 оценок)
Полный доступ
Позволит учиться лучше и быстрее. Неограниченный доступ к базе и ответам от экспертов и ai-bota Оформи подписку
logo
Начни делиться знаниями
Вход Регистрация
Что ты хочешь узнать?
Спроси ai-бота