there fence Polycarpuss home the fence consist n plank width leave right the height ith plank hi meter distinct plank distinct height Fence n7 h1261171 Polycarpus buy posh piano thinking house in order carry plan need exactly k consecutive plank fence high plank harder tear fence Polycarpus wants find k consecutive plank sum height minimal possiblewrite program find index k consecutive plank minimal total height pay attention fence Polycarpuss home home word fence is not cyclic