Look for a lamp cord set at a hardware store or online (but make sure the switch is attached to the cord, not the socket). Or, buy each component individually and make one yourself—it takes less time than drinking a smoothie. Here's a walk-through: To attach the socket to the cord, use an X-acto knife to split the cord into two strips about an inch down from one end, then scrape away the insulation on each strip to expose a few centimeters of copper wire.
On the base of the socket, loosen the gold and silver screws and twist the copper wire clockwise around each screw shaft underneath the head. One side of the lamp cord will be marked with a stripe or ridge (or the wire itself might be darker); connect this side to the silver screw and the other wire to the gold screw.