Resistors are electrical components that oppose the flow of either direct or alternating current. They are used to protect, operate, or control circuits.
Switches are used to allow electric current to flow when closed. When opened, they prevent current flow. Common switch types include pushbutton, rocker, toggle, rotary coded DIP, rotary DIP, key lock, slide, snap action, and reed.