SpaceX interview question

how does a voltage regulator work?