Hello all,

I am studying for the CompTIA Network+ exam and have a question about subnetting. The example given is that a cafe requires 3 different networks. One for guests, one for employees and another for wireless. The formula for determining how many subnets you create is 2^y. In this case, we want to create 3 therefore, 2^2 which is 4. So why is it that in a subnet of 255.255.255.0, you only go back two bits vice 4? I can't help but think that there is some common knowledge here that I am missing.

As always, any assistance is greatly appreciated.

Ok, the traditional equation is 2^n-2. The reason is the not all routers will support the use of the first and last subnet IDs. There is an explanation if you are interested.

I have a high level overview if you are interested:
http://www.itgeared.com/articles/1347-cidr-and-subnetting-tutorial/

If they are teaching 2^n these days, that's fine. For three subnets, you would use two bits for four subnets.

I also have an online subnet calculator use can use to apply different masks and see the results.
http://www.itgeared.com/tools/ip-subnet-calculator/

The subnet mask you can use for three subnets using your formula is 255.255.255.192. We moved to the right 2 bits.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.