#include using namespace std; const int nmax=2e5+42,MX=14e6; struct info { int l,r; long long sum; }; info tree[MX]; int POINTER_NEXT; int get_node(int node) { if(node>0)return node; node=POINTER_NEXT; POINTER_NEXT++; return node; } void update(int node,int l,int r,int pos,int val) { //cout<<"update "<b.v; } vector< pair > updates[nmax]; long long sum[nmax]; int parent[nmax]; int root(int node) { if(node==parent[node])return node; parent[node]=root(parent[node]); return parent[node]; } void my_merge(int u,int v) { u=root(u); v=root(v); if(updates[u].size()0)my_merge(edges[i].u,edges[i].v); else { outp[-edges[i].v]=ask_value(edges[i].u,-edges[i].v); } } for(int i=1;i<=q;i++) if(PRINT[i])printf("%lld\n",outp[i]); } int main() { freopen("thief.in","r",stdin); freopen("thief.out","w",stdout); int t=1; while(t) { t--; solve(); } return 0; } /* 7 5 1 3 2 3 10 1 1 1 2 4 2 3 7 1 4 6 2 5 10 5 6 3 1 7 15 1 1 7 2 2 100 1 1 7 1 2 10 1 7 14 9 106 117 1 */