IP addresses
an IP address is a bunch of numbers that computers use to connect to each other on the internet.
ip address —> 203.0.113.7
each of these numbers are actually used to represent binary digits of 0-8 (00000000 is 0 —> 11111111 is 8 in binary)
the above ip address in binary (left is padded with zeroes) —> 11001011.00000000.01110001.00000111
an ip address (ipv4, not ipv6) is 32 bit in length because xxx.xxx.xxx.xxx <— each bunch of numbers separated by dots represents 8 bits. when you send all 4 pieces of 8 bits together, you get 32 bits of information. therefore an ip address (v4) is 32bit in size.
more: https://www.quora.com/What-does-it-mean-if-an-IP-address-is-made-up-of-32-bits
what is a subnet
https://www.cloudflare.com/learning/network-layer/what-is-a-subnet/