Simon likes drilling tunnels parallel to the ground. Simon has drilled
Input Specification
The first line of input will contain the single integer
For each of the next
Output Specification
On one line, the length of the longest tunnel.
Sample Input
Copy
3
1 8
9 150
0 81
Sample Output
Copy
141
Comments
Sean Combs
what if two tunnels are the same length?
down voting so toxic. valid question bro
You only need to find the longest tunnel, so you can choose either tunnel (if they're tied for the maximum length).
indeed, since your printing out the length not which tunnel it is