<span>#include <iostream>
int main()
{
unsigned int n;
unsigned int square;
while (std::cin >> n){
for (unsigned int i = 1; i < n; ++i){
square = i*i;
if (square <= n) std::cout << i << ", ";
else {
std::cout << std::endl << i;
break;
}
}
};
}<span>
</span></span>
C++
#include <iostream>
using namespace std;
int main() {
int a, b, c;
cin >> a >> b >> c;
if ((a + b + c) == 180 ) {
cout << "These are the angles of the triangle" << endl;
if ((a == 90) || (b == 90) || (c == 90)) {
cout << "Rectangular";
} else {
cout << "Not rectangular";
}
} else {
cout << "These are not the angles of the triangle";
}
return 0;
}
Var
a, b: integer;
begin
write('Первое число: ');
readln(a);
write('Второе число: ');
readln(b);
writeln('Сумма квадратов A и B: ', sqr(a) + sqr(b));
writeln('Произведение квадратов A и B: ', sqr(a) * sqr(b));
writeln('Разность квадратов A и B: ', sqr(a) - sqr(b));
end.
Ожидаем, что таблица истинности покажет значение для полученной конъюнкции, т.е. выражение будет истинным при любом С и одновременно при при истинных А и В.
Таблица истинности дана во вложении.
В ячейки D2 - D4 необходимо вставит формулу СРЗНАЧА(B2:C2) Решение в файле