Switches are more advanced than hubs and less capable than routers. Unlike hubs, switches can limit the traffic to and from each port so that each device connected to the switch has a sufficient amount of bandwidth. For this reason, you can think of a switch as a "smart hub." However, switches don't provide the firewall and logging capabilities that routers do. Routers can often be configured by software (typically via a Web interface), while switches only work the way the hardware was designed.
The term "switch" can also be used to refer to a small lever or button on computer hardware. And while it has nothing to do with computers, "riding switch" means riding backwards in skateboarding and snowboarding.