Infosys interview question

What is a diode? And how does it work?