方程少年会遇到解小姐吗
You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.
Description
众所周知,含有个未知数的个方程有唯一的解。当方程的个数小于未知数的个数时,我们称之为不定方程,不定方程会有无穷多组解。但是不一定有整数解。婷婷最近对不定方程很感兴趣,她决定研究一类最简单的不定方程,形如,希望你能告诉她,这个方程是否有整数解。
Format
Input
第一行一个数,表示有个系数。 第二行个数,表示不定方程的系数,系数不会超过。 第三行一个数。
Output
如果有解输出YES,否则输出NO。
Samples
2
3 5
10
YES
SDNU_ACM_ICPC_2024_WEEKLY_PRACTICE_4th
- Status
- Done
- Rule
- ACM/ICPC
- Problem
- 12
- Start at
- 2024-11-17 18:00
- End at
- 2024-11-17 22:00
- Duration
- 4 hour(s)
- Host
- Partic.
- 38