In: Computer Science
What is the subnet address for a host with the IP address 200.0.0.26 /29
200.0.0.8 |
||
200.0.0.12 |
||
200.0.0.20 |
||
200.0.0.24 |
||
20.0.0.16 |
d) 200.0.0.24 Explanation: ------------- IP Address: 200.0.0.26 ---------------------------------------- Let's first convert this into binary format 200.0.0.26 Let's convert all octets to binary separately Converting 200 to binary Divide 200 successively by 2 until the quotient is 0 > 200/2 = 100, remainder is 0 > 100/2 = 50, remainder is 0 > 50/2 = 25, remainder is 0 > 25/2 = 12, remainder is 1 > 12/2 = 6, remainder is 0 > 6/2 = 3, remainder is 0 > 3/2 = 1, remainder is 1 > 1/2 = 0, remainder is 1 Read remainders from the bottom to top as 11001000 So, 200 of decimal is 11001000 in binary 200 in binary is 11001000 Converting 0 to binary Divide 0 successively by 2 until the quotient is 0 Read remainders from the bottom to top as So, 0 of decimal is in binary 0 in binary is 00000000 Converting 0 to binary Divide 0 successively by 2 until the quotient is 0 Read remainders from the bottom to top as So, 0 of decimal is in binary 0 in binary is 00000000 Converting 26 to binary Divide 26 successively by 2 until the quotient is 0 > 26/2 = 13, remainder is 0 > 13/2 = 6, remainder is 1 > 6/2 = 3, remainder is 0 > 3/2 = 1, remainder is 1 > 1/2 = 0, remainder is 1 Read remainders from the bottom to top as 11010 So, 26 of decimal is 11010 in binary 26 in binary is 00011010 ================================================================================= || 200.0.0.26 in binary notation is 11001000.00000000.00000000.00011010 || ================================================================================= Subnet mask is /29 For Calculating network ID, keep first 29 bits of 11001000.00000000.00000000.00011010 and set all remaining bits to 0. so, network ID in binary is 11001000.00000000.00000000.00011000 11001000.00000000.00000000.00011000: ---------------------------------------- 11001000.00000000.00000000.00011000 Let's convert all octets to decimal separately Converting 11001000 to decimal Converting 11001000 to decimal 11001000 => 1x2^7+1x2^6+0x2^5+0x2^4+1x2^3+0x2^2+0x2^1+0x2^0 => 1x128+1x64+0x32+0x16+1x8+0x4+0x2+0x1 => 128+64+0+0+8+0+0+0 => 200 11001000 in decimal is 200 Converting 00000000 to decimal Converting 00000000 to decimal 00000000 => 0x2^7+0x2^6+0x2^5+0x2^4+0x2^3+0x2^2+0x2^1+0x2^0 => 0x128+0x64+0x32+0x16+0x8+0x4+0x2+0x1 => 0+0+0+0+0+0+0+0 => 0 00000000 in decimal is 0 Converting 00000000 to decimal Converting 00000000 to decimal 00000000 => 0x2^7+0x2^6+0x2^5+0x2^4+0x2^3+0x2^2+0x2^1+0x2^0 => 0x128+0x64+0x32+0x16+0x8+0x4+0x2+0x1 => 0+0+0+0+0+0+0+0 => 0 00000000 in decimal is 0 Converting 00011000 to decimal Converting 00011000 to decimal 00011000 => 0x2^7+0x2^6+0x2^5+1x2^4+1x2^3+0x2^2+0x2^1+0x2^0 => 0x128+0x64+0x32+1x16+1x8+0x4+0x2+0x1 => 0+0+0+16+8+0+0+0 => 24 00011000 in decimal is 24 ================================================================================== || 11001000.00000000.00000000.00011000 in decimal notation is 200.0.0.24 || ================================================================================== ========================================= || So, Network ID is 200.0.0.24 || =========================================