After a week, the judge has accepted my solution.gmacar wrote:Are there any tricky cases?
I'm always getting WA.
Guys, watch out... the output for s=0 can be deceptive.

After a week, the judge has accepted my solution.gmacar wrote:Are there any tricky cases?
I'm always getting WA.
Code: Select all
6 6 10
1 2
2 3
3 4
3 5
4 5
4 6
1 2
1 6
2 3
3 5
5 3
5 4
4 3
4 1
6 4
6 2
0 0 0