#CCBCHBAHAI0000084. Initializer một phần - phần còn lại bằng 0 (Partial Initializer - Remaining Elements Are Zero)
Initializer một phần - phần còn lại bằng 0 (Partial Initializer - Remaining Elements Are Zero)
Partial Initializer - Remaining Elements Are Zero
Source: Programming in C
Version: Phuoc Hung OJ Extended
Problem Statement
An array declaration has size and provides exactly initializer values, with . These values initialize . Under the C initialization rules, every remaining element from through is initialized to .
Construct and print the complete initialized array.
Input
- The first line contains and .
- The second line contains exactly integers from the initializer.
Output
Print all elements after initialization, separated by single spaces.
Subtasks
Subtask 1 (20 points): , , .
Subtask 2 (30 points): , , .
Subtask 3 (50 points): , , .
Examples
Input
6 3
4 -2 7
Output
4 -2 7 0 0 0
Explanation
The array has elements, but only initializer values: . Hence , , and . The omitted elements are all initialized to .