Score : $400$ points
Given is a string $S$ of length $N$ consisting of lowercase English letters.
Snuke can do this operation any number of times: remove fox
occurring as a substring from $s$ and concatenate the remaining parts of $s$.
What is the minimum possible length of $s$ after some number of operations by Snuke?
Input is given from Standard Input in the following format:
$N$ $s$
Print the minimum possible length of $s$ after some number of operations by Snuke.
6 icefox
3
fox
at the end of icefox
, we can turn $s$ into ice
.7 firebox
7
fox
does not occur as a substring.48 ffoxoxuvgjyzmehmopfohrupffoxoxfofofoxffoxoxejffo
27