How to find network number from IP Address&Broadcast IP.

I think , how to find network number is very basic knowledge of computer network but I don’t remember. However, after I reviewed my notebook training , I found it again.

These are solution :

1. Convert IP Address to binary number ,

192.168.0.1 => 1100 0000 . 1010 10000 . 0000 0000 . 0000 0001

2. Convert Broadcast IP to binary number ,

255.255.255.0 => 1111 1111 . 1111 1111 . 1111 1111 . 0000 0000

3. Bring binary IP Address operate with Broadcast IP by AND operation,

1100 0000 . 1010 1000 . 0000 0000 . 0000 0001
and
1111 1111 . 1111 1111 . 1111 1111 . 0000 0000

=

1100 0000 . 1010 1000 . 0000 0000 . 0000 0000

4. Convert this result to decimal number.

192 . 168 . 0 . 0 <= This is Network number.