Dynamic Tree
You are given a tree containing N vertices. The vertices are numbered from 1 to N. A tree with N ver...
A Perfect Binary Tree
A perfect binary tree is a binary tree in which all interior nodes have two children and all leaves ...
Path Intersection Extended
Do you remember the problem from ICPC Dhaka Regional 2018 named $Path$ $Intersection$ by Md. Imran B...
Water in a Tree
There is a tree consist of N nodes and N−1 edges. The ith node contains Si​ liters of water with a t...
Cheap Tourist
The country of Byteland is divided into N provinces numbered from 1 to N. The provinces are connecte...
Toph uses cookies. By continuing you agree to our Cookie Policy.