A diode aka p-n junction is another interesting semiconductor device. It is a two-terminal device: one terminal is called the p junction and the other terminal is called the n junction. When you connect a diode to an electrical circuit, you better know which terminal is which because the diode allows the current to flow in one direction only.
If the voltage applied is such that the p junction is at a higher potential than n junction, the diode is said to be in forward bias. Conversely, if the voltage applied is such that the n junction is at a higher potential than the p junction, the diode is said to be in reverse bias.
An ideal diode should present zero resistance in forward bias, and infinite resistance in reverse bias. Basically, an ideal diode is a perfect one-way valve.
A practical diode requires a small amount of forward bias (called the turn-on voltage) before it switches on. Nevertheless, with sufficient forward bias, it resistance decreases rapidly and soon behaves like a 0-W wire connection. A practical diode also allows a very tiny amount of current (called the reverse current) in reverse bias. Nevertheless, the resistance remains large and it behaves practically like an open circuit.