There are N colored beads placed in a row in front of Hongjun. Beads may share colors or all differ. Whenever K or more beads of the same color are next to each other, that whole run of beads can be cleared at once. Clearing does not have to be done right away; it may be postponed until later.
Hongjun has plenty of spare beads, so he may insert a bead of any color he likes into any gap between the existing beads, including before the first bead and after the last bead.
Write a program that finds the minimum number of beads he must insert so that, eventually, every bead can be cleared.
The first line contains N and K. (1 ≤ N ≤ 100, 2 ≤ K ≤ 5)
The second line contains the colors of the beads in order from left to right. Each color is a natural number between 1 and 100 inclusive.
Print the minimum number of beads that must be inserted in order to clear all of the beads.