Advertisement
Guest User

Untitled

a guest
Feb 24th, 2020
139
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pascal 0.29 KB | None | 0 0
  1. var n,a,p: integer;
  2. var c: string;
  3. begin
  4.     c:= 'нет';
  5.     read(n);
  6.     p:= -1;
  7.     while n > 0 do
  8.         begin
  9.             a:= n mod 10;
  10.             n:= n div 10;
  11.             if p = a then
  12.                 c := 'да';
  13.        
  14.             p:= a;
  15.         end;
  16.     writeln(c);
  17. end.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement