allekco

Вопрос 4

Oct 23rd, 2019
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.30 KB | None | 0 0
  1. var
  2. a, num, i, count, marker: integer;
  3. begin
  4. readln(num);
  5. a := num;
  6. i := 1;
  7. count := 0;
  8. while i <= 4 do
  9. begin
  10. marker := a mod 10;
  11. if marker mod 2 = 0 then count := count + 1;
  12. a := a div 10;
  13. i := i + 1;
  14. end;
  15. writeln(count);
  16. end.
Add Comment
Please, Sign In to add comment