Question: how cmos can be used as switch?
Answer: Transmission gates act like voltage-controlled switches, and being switches, CMOS transmission gates can be used for switching both analogue and digital signals passing the full range of voltages (from 0V to VDD) in either direction, which as discussed is not possible with a single MOS device.