#K73407. Sara's Marathon Qualification
Sara's Marathon Qualification
Sara's Marathon Qualification
Sara participates in an exciting marathon where she earns different points at each checkpoint. Given the number of checkpoints \(n\) and a list of integers representing the points earned at each checkpoint, your task is to compute her total points. Then, compare the total with a given threshold \(m\) to determine if she qualifies for a prize. Formally, if \(T = \sum_{i=1}^{n} p_i\) and \(T \ge m\), then Sara is considered Qualified; otherwise, she is Not Qualified.
inputFormat
The input is given via standard input (stdin) and contains three lines:\n1. The first line contains an integer (n), representing the number of checkpoints.\n2. The second line contains (n) space-separated integers, each representing the points awarded at a checkpoint.\n3. The third line contains an integer (m), the threshold that determines qualification.
outputFormat
Print a single line to standard output (stdout) containing two values separated by a space: the total points accumulated and the qualification status. The status is "Qualified" if the total points are greater than or equal to (m), and "Not Qualified" otherwise.## sample
5
10 -2 5 3 7
15
23 Qualified