Read a Lamp Cord's Polarity by Feel: Ribbed Is Neutral, Smooth Is Hot
Two-wire lamp and appliance cords look interchangeable, but they're marked — the conductor with the ribbed jacket is the neutral, the smooth one is the hot. Wiring them backward puts the switch and socket threads on the live side.