PrideLogic Interview Question

How does virtual dom work in React?