more subnetting

I'm trying to figure out without a subnet calc how to get a subnet mask when given a range of ip addresses

Example: - -
There has to be some method to this.  Can someone help me out.
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Keith AlabasterEnterprise ArchitectCommented:
That info would not be sufficient necessarily on its own as you have not dictated how many subnets would be required from that range or how many hosts were needed in each subnet.

For example, the obvious subnet mask for your second example would be if this were to be all one subnet but.....
tbonehwdAuthor Commented:
OK that's all the info I got.
Keith AlabasterEnterprise ArchitectCommented:

the long and short of it is simply experience and practice.

I got to the mask I gave is as follows:

the first two octects of the start and end address are the same - 118.67 so the first 16 bits - 8 in each are matched the same so this equates to 255.255. - 128+64+32+16+8+4+2+1 = the 8 bits in the octet.

The third octet is different and has 64 making up the difference : 128 - 192 so 256 (.0 - .255) / 64 = 4.
looking at the mask, we know the following is true in an octet
8 7 6 5 4 3 2 1 - bit number
128 64 32 16 8 4 2 1 - value

We start from the left so two bits = bits 8 and bit 7= the 128 and the 64. 128 + 64 = 192 - the third octet
and so on.

There are lots of walk throughs of this written by people that you can Google but once you have the hang of things you don't need a calculator at all.


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
tbonehwdAuthor Commented:
Thanks that makes sense
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.