#C11984. Allowed Riders

    ID: 41360 Type: Default 1000ms 256MiB

Allowed Riders

Allowed Riders

You are given a list of visitor heights and two integers min_height and max_height. Your task is to filter the visitors who are allowed to board the ride based on their heights. A visitor is allowed if and only if their height h satisfies the inequality \( min\_height \le h \le max\_height \).

You need to read the input from stdin and output the result to stdout as a space separated list of allowed heights. If no visitor qualifies, output an empty line.

inputFormat

The input consists of two lines. The first line contains three integers: n min_height max_height, where n is the number of visitors, min_height is the minimum allowed height, and max_height is the maximum allowed height. The second line contains n integers representing the heights of the visitors. When n is zero, the second line may be empty.

outputFormat

Output a single line containing the heights of visitors that satisfy \( min\_height \le h \le max\_height \) in the same order as input, separated by a single space. If there is no such visitor, output an empty line.

## sample
6 150 180
160 150 170 145 180 175
160 150 170 180 175