#420. I love tree
I love tree
Description
Given a tree with nodes and operations, there are two kinds of operations.
: for a chain , increase the value of to the x-th point on this chain for example the chain from a to b=(),after the operation,
:asks the value of x-th node
Format
Input
There is only one test case for this question.
The first line contains one integer .
The next line contains two integers u,v,which means that there is an edge between and .
The next line contains one integer .
The i-th of the following lines is in one of the formats:
Output
Each line output one integer represents the answer.
Samples
3
1 2
2 3
5
1 1 2
2 1
1 2 1
2 2
2 3
1
5
0