P16837 [GKS 2021 #A] K-Goodness String
Description
Charles defines the goodness score of a string as the number of indices $i$ such that $S_i \ne S_{N-i+1}$ where $1 \le i \le N/2$ ($1$-indexed). For example, the string `CABABC` has a goodness score of $2$ since $S_2 \ne S_5$ and $S_3 \ne S_4$.
Charles gave Ada a string $S$ of length $N$, consisting of uppercase letters and asked her to convert it into a string with a goodness score of $K$. In one operation, Ada can change any character in the string to any uppercase letter. Could you help Ada find the minimum number of operations required to transform the given string into a string with goodness score equal to $K$?
Input Format
The first line of the input gives the number of test cases, $T$. $T$ test cases follow.
The first line of each test case contains two integers $N$ and $K$. The second line of each test case contains a string $S$ of length $N$, consisting of uppercase letters.
Output Format
For each test case, output one line containing `Case #x: y`, where $x$ is the test case number (starting from $1$) and $y$ is the minimum number of operations required to transform the given string $S$ into a string with goodness score equal to $K$.
Explanation/Hint
In Sample Case #$1$, the given string already has a goodness score of $1$. Therefore the minimum number of operations required is $0$.
In Sample Case #$2$, one option is to change the character at index $1$ to `B` in order to have a goodness score of $2$. Therefore, the minimum number of operations required is $1$.
### Limits
$1 \le T \le 100$.
$0 \le K \le N/2$.
**Test Set $1$**
$1 \le N \le 100$.
**Test Set $2$**
$1 \le N \le 2 \times 10^5$ for at most $10$ test cases.
For the remaining cases, $1 \le N \le 100$.