Wolfspeed interview question

how do a diode work?