Предмет: Информатика, автор: kirisatyan

Запишите значение переменной s, полученное в результате работы следующей программы.
var s,k: integer;
begin
s := 3;
for k := 0 to 9 do
s := s + 3 ;
writeln(s);
end.

Ответы

Автор ответа: roctii
2

Ответ:

s=33

там цикл выполняется 10 раз, тк k:=0 to 9

получается, что 3 прибавляют 10 раз (3*10=30)

и прибавляют это к изначальной s, которая равна 3 (30+3=33)


kirisatyan: о, теперь я, кажется,понимаю как решать такие задачи...
roctii: могу подробно расписать решение, если нужно
Похожие вопросы
Предмет: Другие предметы, автор: Аноним
Предмет: Английский язык, автор: Songbird1917

8 класс!
Тест №1

Выберите правильный вариант ответа. Choose the correct variant:

The building ______ two years ago.
destroyed
was destroyed
I ______ by the news he had told me the day before.
am surprising
surprised
was surprised
am surprised 
______ he ______ at the airport tomorrow?
Is … being met
Will … be meet
The police ______ to me. 
is hands
was handed
will be handing
I ______ into buying a motorbike by Martha.
was talked
talk
have been talked
Yesterday the whole programme ______ over to a report from Bosnia.
has been given
was given
gave
gives
A number of priceless works of art ______ in the earthquake.
have been destroyed
was destroyed
has been destroyed
Because my visa had expired I ______ from re-entering the country. 
prevented
am prevent
prevent
was prevented
It’s generally agreed that new industries ______ for the southern part of the country.
are need
are needed
need
It’s incredible to think that these clothes ______ by Queen Victoria.
wear
are being worn
were worn
A new drug ______ to combat asthma in small children.
is developing
has been developed
developes
A number of political prisoners ______ within the next week.
will be released
release
were released
The problem ______ to me.
was saying
was mentioned
was being mentioning
The game ______ to the children.
demonstrates
was demonstrate
is demonstrating
will be demonstrated
When I was young I ______ by my aunt and uncle.
was looked for 
was looked after
was looked at
was being looked
He ______ for nearly 12 hours.
operates with
is operated at
was operated on
His decision ______.
approves of
was approved of
The land next to our house ______.
has been bought
have been bought
was being bought
The tennis court ______ so we couldn’t play.
has been used
was used
was being used
Better results ______ soon.
will be expected
are expected
expect