88 views

I am getting M1 as correct.

### 4 Comments

Class B = 10100000.00011000.11011111.11111111
M1         = 11111111.11111111.11010000.00000000
M2         = 11111111.11111111.11100000.00000000
M3          = 11111111.11111111.11110000.00000000

When we will do AND operation of class B with M1 we will get 160.24.208.0

Which is actually matching.

Tell me where I am wrong.

@Kabir5454 your opinion please.

In the question the given IP is broadcast address of the network not the IP address of the host .
They are considering only continuous subnet mask. If not, then I think all three are correct.

## 1 Answer

I am not totally sure about it, but just going through some stack overflow answers i think you should consider the mask until we get contiguous string of 1’s, So in case of M1, we have effective subnet mask as 255.255.11000000.0

So, as we have given class B network so that will be 160.24.11011111.255, since the third bit is zero your subnet shoud be atleast 224 or more in third octet. So that’s why M2 and M3.

I am not totally sure about first part someone correct if I am wrong.

### 1 comment

The given IP is Broadcast Address of the subnet

$B=10100000.00011000.11011111.11111111$

It is broadcast address .

In broadcast address all the host ID part is $1’s$.

So what we can conclude from this broadcast address ?

=> 10100000.00011000.110 → This portion at least has to be in network id portion . The bits after this 19 bits  may or may not be in  network id portion we are not sure about that but this 19 (yellow marked bits) definitely network id bits because in broadcast address all the host id bit should be $’0’$ but here we got $’0’$ at 19 th bit which confirm first 19 bit should be network id portion rest may or may not be in network id portion we don’t know .

Now subnet mask :- In subnet mask all the network id part bit should be $’1’$ and Host Id part bit should be ‘0’ .

Now If we check the option :-

1. $M1$=11111111.11111111.11010000.00000000 → This marked 3 bits belongs to network id portion  should be $1$ in subnet mask but here it is $0$ . So  it should not be valid subnet mask .
2. $M2$=11111111.11111111.11100000.00000000 → This marked 3 bits belongs to network id portion is $1$ in subnet mask . So  it should  be valid subnet mask .
3. $M3$=11111111.11111111.11110000.00000000 → This marked 3 bits belongs to network id portion is $1$ in subnet mask . So  it should  be valid subnet mask .
4. Even this ,$M4$=11111111.11111111.11111000.00000000 → This marked 3 bits belongs to network id portion is $1$ in subnet mask . So  it should  be valid subnet mask .

From the given information we can only conclude this .