Home > DeveloperSection > Interviews > Why Array Index starts from Zero?

Posted on    July-23-2011 7:36 AM

 Visual C++ Visual C++ 
 1 Answer(s)
  1834  View(s)
Rate this:

James Smith

Total Post:79

Posted on    July-23-2011 12:00 AM

This boils down to the concept of Binary digits. Take an array size of 64 for example. We start from 0 and end at 63. We require 6 bits.But, if we were to start from 1 and end at 64, we would require 7 bits to store the same number, thus increasing the storage size.

Don't want to miss updates? Please click the below button!

Follow MindStick