if __name__ == "__main__":
n = int(input())
results = input()
tests_per_group = n // 10
all_passed = "T" * tests_per_group
points = [
1
for i in range(0, len(results), tests_per_group)
if results[i : i + tests_per_group] == all_passed
]
print(sum(points))
1 2 3 4 5 6 7 8 9 10 11 12 | if __name__ == "__main__": n = int(input()) results = input() tests_per_group = n // 10 all_passed = "T" * tests_per_group points = [ 1 for i in range(0, len(results), tests_per_group) if results[i : i + tests_per_group] == all_passed ] print(sum(points)) |
English