cf/mirror

Make Almost Equal With Mod

CF
1909B1200· pupil1s256 MB⌨ stdin/stdout

Examples

Sample 1of 1multi-test • hover to link
Input
5
4
8 15 22 30
5
60 90 98 120 308
6
328 769 541 986 215 734
5
1000 2000 7000 11000 16000
2
2 1
Output
7
30
3
5000
1000000000000000000
1909B.cpp
loading editor…
Ln 11·137 BGNU C++20 (64)