Ниже на языке прогаммирования паскаль записаны две рекурсивные функции (процедуры): F и G. Сколько символов "звездочка" будет напечатано на экране при выполнении вызова F(20)?
Procedure F(n: integer) ; forward;
Procedure G(n: integer) ; forward;

procedure F(n: integer) ;
Begin
Write ('*');
If n > 10 then F(n-2) else G(n);
End;

Procedure G(n: integer) ;
Begin
Write ('**');
If n > 1 then F(n-3);
End;
Обьясните пожалуйста, как это делать, если можете, то распишите пожалуйста подробно.
Please enter comments
Please enter your name.
Please enter the correct email address.
You must agree before submitting.

рекомендуемые вопросы

Copyright © 2025 SCHOLAR.TIPS - All rights reserved.