Number of Nodes With Value One
Mark each queried node once; a node's value is the parity of marks on itself and its ancestors, found in one top-down pass.
Mark each queried node once; a node's value is the parity of marks on itself and its ancestors, found in one top-down pass.