#96. pre4

pre4

Background

Description

Given a non-empty array of ints, return a new array containing the elements from the original array that come before the first 4 in the original array. The original array will contain at least one 4. Note that it is valid in java to create an array of length 0.

Format

Input

Output

Samples

[1 2 4 1]
[1, 2]
[3 1 4]
[3, 1]
[1 4 4]
[1]

Limitation

1s, 1024KiB for each test case.