{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
import qualified Data.ByteString.Char8 as B
import qualified Data.Maybe as Maybe
import qualified Data.Char as Char
import qualified Data.List as List
import           Data.Vector.Unboxed ((!))
import qualified Data.Vector.Unboxed as UV
import Data.Function ((&))
import Debug.Trace
import Control.Monad

main :: IO ()
main = do
    input <- runParser parseInput <$> B.getContents
    solve input & map show & List.intercalate "\n" & putStrLn

data Input = Input
    { nDays :: !Int
    , nWork :: !Int
    , nRest :: !Int
    , canWork :: UV.Vector Bool
    }

parseInput :: Parser Input
parseInput =
    Input
        <$> parseInt
        <*> parseInt
        <*> parseInt
        <*> (toVector <$> parseWord)
  where
    toVector :: B.ByteString -> UV.Vector Bool
    toVector bs =
        B.unpack bs
        & map (\c -> c == 'o')
        & UV.fromList

solve :: Input -> [Int]
solve Input{..} =
    -- 前から貪欲に働く日を決めた場合を考えることで「x回目に働く日はL[x]日後以降」という配列Lを求めることができる。
    -- 同様に後ろから貪欲に働く日を決めた場合を考えることで「x回目に働く日はR[x]日目以前」という配列Rを求めることができる。
    -- i日目に必ず働くのは、L[x]=R[x]=i となるxが存在するときに限る。

    let
        dpL i lastWork nWorked =
            if i >= nDays || nWorked >= nWork then
                []
            else if (canWork ! i) && (i - lastWork > nRest) then
                i : dpL (i+1) i (nWorked+1)
            else
                dpL (i+1) lastWork nWorked

        dpR i lastWork nWorked =
            if i < 0 || nWorked >= nWork then
                []
            else if (canWork ! i) && (lastWork - i > nRest) then
                i : dpR (i-1) i (nWorked+1)
            else
                dpR (i-1) lastWork nWorked

        l = dpL 0 (-99999999) 0
        r = dpR (nDays - 1) 99999999 0 & reverse
    in
        zip l r
        & filter (\(x, y) -> x == y)
        & map fst
        & map (+1)

-------------------------------------------------------------------------------

newtype Parser a =
    Parser (B.ByteString -> (a, B.ByteString))

instance Functor Parser where
    fmap f (Parser parser) =
        Parser $ \input ->
            let (v, remainder) = parser input in
                (f v, remainder)

instance Applicative Parser where
    pure v =
        Parser $ \input ->
            (v, input)

    (Parser parser1) <*> (Parser parser2) =
        Parser $ \input ->
            let
                (f, remainder1) = parser1 input
                (v, remainder2) = parser2 remainder1
            in
                (f v, remainder2)

instance Monad Parser where
    return = pure

    (Parser parser1) >>= f =
        Parser $ \input ->
            let
                (v, remainder) = parser1 input
                Parser parser2 = f v
            in
                parser2 remainder

consumeSpace :: Parser ()
consumeSpace =
    Parser $ \input ->
        ((), B.dropWhile Char.isSpace input)

lexeme :: Parser a -> Parser a
lexeme parser =
    consumeSpace *> parser

parseInt :: Parser Int
parseInt =
    lexeme $ Parser $ \input ->
        Maybe.fromJust (B.readInt input)

parseWord :: Parser B.ByteString
parseWord =
    lexeme $ Parser $ \input ->
        B.span (not . Char.isSpace) input

runParser :: Parser a -> B.ByteString -> a
runParser (Parser parser) input =
    fst $ parser input

-------------------------------------------------------------------------------
