A hairdryer has a plastic case. Why can it be connected to the mains using a cable that has only two wires?
The neutral wire is able to do the job of the earth wire
Plastic has a much lower resistance than metal does
A plastic case cannot carry a current to the neutral wire
A plastic case cannot become live, so no earth wire is needed