Lecture 5
Lecture 5
IPv4 Addresses
Note
Solution
We replace each group of 8 bits with its
equivalent decimal number and add dots for
separation:
c. 231.219.139.111
d. 249.155.251.15
Solution
We replace each decimal number with its
binary equivalent:
c. 11110001 00001000 00111000 00001100
d. 01001011 00101101 00100010 01001110
Solution
a. There should be no leading zeroes (045).
b. We may not have more than 4 bytes in an
IPv4 address.
c. 75.45.301.14
d. 11100010.23.14.67
Solution
Solution
We replace each group of 4 bits with its hexadecimal
equivalent. Note that 0X (or 0x) is added at the beginning or the
subscript 16 at the end.
a. 0X810B0BEF or 810B0BEF16
b. 0XC1831BFF or C1831BFF16
Solution
We can subtract the first address from the last address in base
256 .The result is 0.0.3.255 in this base. To find the number of
addresses in the range (in decimal), we convert this number to
base 10 and add 1 to the result..
Solution
We convert the number of addresses minus 1 to base 256,
which is 0.0.0.31. We then add it to the first address to get the
last address. Addition is in base 256.