Sponsored
Sponsored
Use these hints if you're stuck. Try solving on your own first.
A node that does not have any incoming edge can only be reached by itself.
Any other node with incoming edges can be reached from some other node.
We only have to count the number of nodes with zero incoming edges.