Registered Users Only

Problem Description

Ranald was given an array of N integers, A. He decides to compress it by applying the following algorithm: take every consecutive segment of K elements and take the maximum. Then create a new array B of length (N - K + 1), where the ith element of this array would represent the maximum element within Ai and Ai+K-1.

Unfortunately, Ranald lost his original array! Given the new array B, help Ranald reconstruct his original array. If there are more than one possible answers, output any.

Input

The first line of input will contain two integers, N and K.

The second line of input will contain (N - K + 1) integers, representing the array B.

Output

The output should contain one line with N integers, representing the array A. All integers should be within 1 and 109.