A circuit-switched network uses dedicated connections between nodes, requiring three phases of connection setup, data transfer, and teardown. Resources are reserved during setup. In contrast, a packet-switched or datagram network divides messages into packets that are routed independently through the network without resource reservation. Each switch uses a routing table to determine the next hop based on the packet's destination address. A virtual-circuit network combines aspects of circuit and datagram switching by establishing virtual circuits with resource reservation but packetizing the data. Switches in these networks use various architectures like crossbar, multistage, time-division, and space-division designs to connect inputs to outputs.