JOIN
Get Time
forums   
Search | Watch Thread  |  My Post History  |  My Watches  |  User Settings
View: Flat (newest first)  | Threaded  | Tree
Previous Thread  |  Next Thread
2045 - Closest Common Ancestors | Reply
Hello,
the input data for this problem is differently formatted from the description in the problem statement.
From the problem statement the input is given like this:
5
5:(3) 1 4 2
1:(0)
4:(0)
2:(1) 3
3:(0)
6
(1 5) (1 4) (4 2)
(2 3)
(1 3) (4 3)

but it's actually :
5
5:(3) 1 4 2
1:(0)
4:(0)
2:(1) 3
3:(0)
6
(1,5)
(1,4)
(4,2)
(2,3)
(1,3)
(4,3)

:-)
I checked the tests after many WA's (http://acm.ro/2000/problems.htm -- see the input for H).
I posted it here in case someone else experiences the same problem.
RSS