Advertisement
Alex_Fomin

Untitled

Feb 16th, 2016
441
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pascal 0.24 KB | None | 0 0
  1. begin
  2.   var n := ReadLnInteger('Введите число N:');
  3.   var count := 0;
  4.   if n <> 0 then
  5.     while n <> 0 do
  6.     begin
  7.       n := n div 10;
  8.       Inc(count)
  9.     end
  10.   else count := 1;
  11.   WriteLn('Ответ: ', count);
  12. end.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement