Urinal Flush Schedule

Time limit1sMemory limit128 MB

Problem

A new urinal model has a sensor and an automatic flush function. Its software must decide when to flush from the sensor log.

The sensor follows these rules:

  • If someone stands in front of the urinal continuously for at least K seconds, the urinal is recorded as in use.
  • After the urinal has been recorded as in use, if nobody stands in front of it for L consecutive seconds, the urinal is recorded as finished. At that moment, the flush function is activated.

The sensor log contains N one-second records starting at time 0. The first character describes the interval from time 0 to time 1, the second character describes the interval from time 1 to time 2, and so on.

At all times outside the given log, nobody is standing in front of the urinal.

Input

The first line contains three integers K, L, and N (1 <= K, L <= 1000, 1 <= N <= 10000).

The second line contains a length-N sequence made of 0 and 1. It represents the data recorded by the sensor. A 0 means nobody is standing in front of the urinal during that second, and a 1 means someone is standing in front of it.

Output

For every time the urinal flushes, print the time measured from the start. The times must be printed in increasing order, one per line.

If the urinal never flushes, print NIKAD.