GE HealthCare interview question

How does undo and redo work in a laptop