P9254 [PA 2022] Liczenie punktów

Description

**This problem is translated from [PA 2022](https://sio2.mimuw.edu.pl/c/pa-2022-1/dashboard/) Round 1 [Liczenie punktów](https://sio2.mimuw.edu.pl/c/pa-2022-1/p/pun/).** The judges of PA are tired of constantly calculating the scores for all submitted programs. Please help them automate this process. For each problem, one submission can score from $0$ to $10$ points. There are $n$ groups of testdata for a problem, and $n$ is divisible by $10$. If the program passes the first $\frac{n}{10}$ groups, it gets $1$ point. If it also passes the next $\frac{n}{10}$ groups, it gets another $1$ point, and so on. A submission earns $1$ point independently for each block of $\frac{n}{10}$ testdata groups that it passes completely. If there is an error in any group inside a block, then the submission gets $0$ points for that block. Notes: 1. For simplicity, we assume that each block contains the same number of testdata groups, but in real programming contests this is not always the case. 2. Any code you have written may be used to mess with you (the astronaut joke).

Input Format

The first line contains an integer $n$, where $n$ is a multiple of $10$, representing the number of testdata groups. The next line contains a string of length $n$ consisting only of `T` and `N`, describing the pass/fail result of each testdata group. `T` means the group is passed, and `N` means the group is not passed.

Output Format

Output one integer on a single line, representing the score of this submission.

Explanation/Hint

For $100\%$ of the data, it holds that: $10\le n\le 100$。 Translated by ChatGPT 5