LCC/Moose '20 Contest 1 S1 - Cheetahs

View as PDF

Submit solution

Points: 5 (partial)
Time limit: 2.0s
Memory limit: 64M

Author:
Problem type

Because of the COVID-19 pandemic, Professor Lily has decded that his students will self-grade and self-report the scores on their assignments. Professor Lily has a class of N students, numbered 1 to N, whom he has asked to self report the scores they received on an assignment with maximum score M.

Can you determine which students failed to report their score correctly?

Input Specification

The first line of input contains two integers N and M, (1 \le N,M \le 100).

The second line of input contains an integer S the number of test scores Professor Lily received, (1 \le S \le 1000).

The next S lines contain two positive integers x_i (1 \le x_i \le N) and y_i (0 \le y_i \le 100), denoting that that student x_i has self-reported that he/she scored y_i on the assignment.

Output Specification

A single line consisting of a list of space separated integers, in increasing order, the students that did not submit their assignment correctly.

Sample Input 1

5 10
5
1 11
3 8
4 3
5 8
5 7

Sample Output 1

1 2 5

Sample Input 2

6 6
6
3 5
1 0
4 3
3 5
5 7
6 2

Sample Output 2

2 5

Comments

There are no comments at the moment.