#C1780. Track Sales Performance
Track Sales Performance
Track Sales Performance
In this problem, you are given the number of departments \(M\) and their corresponding weekly sales figures. You are also given a weekly target sales figure \(T\). Your task is to determine which departments met or exceeded the target. Departments are indexed from \(0\) to \(M-1\). The output should be the indices of the qualifying departments in ascending order.
Input: The first line contains two integers \(M\) and \(T\) (the number of departments and the target sales figure, respectively). The second line contains \(M\) integers representing the sales figures of each department.
Output: Print the indices (0-indexed) of the departments that have a sales figure greater than or equal to \(T\). The indices should be printed in ascending order, separated by spaces. If no department meets the target, output an empty line.
inputFormat
The input is provided via standard input. It contains two lines:
- The first line consists of two integers \(M\) and \(T\) separated by a space.
- The second line contains \(M\) integers which are the sales figures for each department.
outputFormat
The output should be printed to standard output. Print the 0-indexed department indices that meet or exceed the target sales figure \(T\), separated by spaces. If no department meets the target, print an empty line.
## sample5 400
300 500 200 450 600
1 3 4