This post was flagged by the community and is temporarily hidden.
Its funny that first line of your code says
we either win, or we learn. XD
PS: I agree with you
@maskmanlucifer I think you should output 0 if you find less than 2 occurrences of k rather than -1. See explanation after the sample output.