cf/mirror

The Curse of the Frog

CF
2189B1200· pupil1s256 MB⌨ stdin/stdout

Examples

Sample 1of 1multi-test • hover to link
Input
6
1 1
3 3 3
1 7
4 2 5
2 4
1 2 3
2 2 4
5 8
12 1 11
10 1 4
1 1 3
1 2 5
2 1 7
1 1000000000000000000
1000000 4 654321
1 10
2 2 1
Output
0
1
-1
2
298892990032
3
2189B.cpp
loading editor…
Ln 11·137 BGNU C++20 (64)