CIDR subnetting
Split 192.168.1.0/24 into four pieces and they start at .0, .64, .128, and .192. None can start at 50. Memorizing the subnetting table, where /26 means 64 and /27 means 32, makes the numbers feel familiar, but a nonstandard boundary or a VLSM split breaks that memory. A CIDR prefix marks where the network bits end, and every boundary calculation reduces to a bit operation at that mark. The sections below walk through that bit operation and check each result with real output from Python’s ipaddress. ...