Logo
(追記) (追記ここまで)

24795번 - Saving Princess Peach 다국어

시간 제한메모리 제한제출정답맞힌 사람정답 비율
1 초 (추가 시간 없음) 1024 MB30015712748.289%

문제

Mario is trying to save his beloved Princess Peach! However, in order to do that, Mario must jump over many obstacles in order to save Princess Peach. Thus, he makes a grand plan to infiltrate Bowser's castle.

But first, he needs to practice. His brother Luigi makes a practice course for Mario to train on. On this course, Mario practices looking for all the possible obstacles that could take away his life. But Mario is sloppy and misses some obstacles, counts some obstacles more than once, and generally screws up the order of the obstacles he does find when he lists them!

Write a program so that Luigi can tell his brother which obstacles he's missed!

입력

The first line contains 2ドル$ values. The first value $N$ (0ドル < N \le 100$) is the total number of obstacles. Obstacles are numbered 0ドル \ldots N-1$.

The second value $Y$ (0ドル \le Y \le 200$) represents how many obstacles Mario said he's found on his practice run. The next $Y$ lines each list a single integer $k$ (0ドル \le k < N$) which is the number of an obstacle Mario says he's found.

출력

First, output the obstacles that Mario missed in increasing order, each on a separate line. On the last line, print Mario got X of the dangerous obstacles. where $X$ is the number of distinct obstacles Mario found.

제한

예제 입력 1

20 4
5
10
12
16

예제 출력 1

0
1
2
3
4
6
7
8
9
11
13
14
15
17
18
19
Mario got 4 of the dangerous obstacles.

힌트

출처

School > Virginia Tech High School Programming Contest > 2017 Virginia Tech High School Programming Contest C번

  • 문제를 만든 사람: Spencer Pao
(追記) (追記ここまで)

출처

대학교 대회

  • 사업자 등록 번호: 541-88-00682
  • 대표자명: 최백준
  • 주소: 서울시 서초구 서초대로74길 29 서초파라곤 412호
  • 전화번호: 02-521-0487 (이메일로 연락 주세요)
  • 이메일: contacts@startlink.io
  • 통신판매신고번호: 제 2017-서울서초-2193 호

AltStyle によって変換されたページ (->オリジナル) /