Toggle navigation
YouTube
Facebook
Telegram
english
english
українська
Algotester 4.3
Build 496
2024-10-17
Log In
Contact Us
College
Sponsors
Donate
Sources
Python 3
n = int(input()) s = input() for i in range(n): if s[i] == '*': print("*", end="") else: res = 0 if i > 0 and s[i - 1] == '*': res += 1 if i + 1 < n and s[i + 1] == '*': res += 1 print(res, end="") print()