Помогите плиз.
Какое значение будет принимать переменная Y после выполнения фрагментов программы?

a) Var Y, X: integer;
Begin
Y: = 0; X: = 10;
While X > 0 do
Begin
X: = x – 2;
Y: = Y + X
End;
Writeln (‘Y=’,Y);
End.
b) Var Y, X: integer;
Begin
Y: = 1; X: = 15;
While X>5 do
Begin
X: = X – 3; Y: = Y * X
End;
Writeln (‘Y = ‘,Y);
End.

Please enter comments
Please enter your name.
Please enter the correct email address.
You must agree before submitting.

Answers & Comments


Copyright © 2024 SCHOLAR.TIPS - All rights reserved.