Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- begin
- var s := '9' * 1000;
- while s.Contains('888') or s.Contains('999') do
- begin
- if s.Contains('888') then
- s := s.Replace('888','9',1)
- else
- s := s.Replace('999','8',1);
- end;
- print(s);
- end.
Advertisement
Add Comment
Please, Sign In to add comment