// language c++
float array[n];
//Zadacha 1
//1)
int answer;
for (i =0, i <n, i++)
{
if (array[0] >= array[i])
array[0] = array[i];
answer = i;
}
cout<<answer;
//2)
int summ;
float array2[n];
for(int i =0, i < n, i++)
{
summ +=array[i];
}
cout<<summ;
//Zadacha2
float massive[n];
for (int i = 0, i < n, i++)
{
if (massive[i] < 0)
massive[i] = -1 * massive[i];
}
//1)
int answer = 0;
for (i =0, i <n, i++)
{
if (massive[0] >= massive[i])
massive[0] = massive[i];
answer = i;
}
cout << answer;
дальше измени сама
var month:integer;
begin
readln(month);
if ((month >0 ) and ( month < 13)) then
case month of
1 : writeln ('january (31 days) ');
2 : writeln ('fabruary (28 days) ');
3 : writeln ('march (31 days)');
4 : writeln ('April (31 days) ');
5 : writeln ('fabruary (28 days)');
6 : writeln ('march (31 days)');
7 : writeln ('january (31 days) ');
8 : writeln ('fabruary (28 days) ');
9 : writeln ('march (31 days)');
10 : writeln ('january (31 days) ');
11 : writeln ('fabruary (28 days) ');
12: writeln ('march (31 days)');
end
else writeln('error');
readln;
end.
Поделитесь своими знаниями, ответьте на вопрос:
Устарой колдуньи есть 2 кувшина ёмкостью 10 литров и 6 литров . как старой ведьме отмерить 3 литра для зелья молодости