array index begins with zero

Posted by Anand under C# on 2/4/2012 | Points: 10 | Views : 841 | Status : [Member] | Replies : 4
Can any one please tell me y does the array index begins with zero
int[] sample = new int[10];

-


Responses

Posted by: Harshparikh on: 2/4/2012 [Member] Starter | Points: 25

Up
0
Down
Array Index always starts with Zero because that is the truth.. we cant change this thing.
We have to accept this funda dear

Anand, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Anand on: 2/4/2012 [Member] Starter | Points: 25

Up
0
Down
but there must be some specific reason for that right

-

Anand, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Anand on: 2/4/2012 [Member] Starter | Points: 25

Up
0
Down
?

-

Anand, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Naraayanan on: 2/4/2012 [Member] Starter | Points: 25

Up
0
Down
Hi anand,
Easy manipulation start from the whole numbers.

Check these link
http://developeronline.blogspot.in/2008/04/why-array-index-should-start-from-0.html


Regards,
Lakshmi Naraayanan.S
http://dotnettechrocks.blogspot.in/
http://abaprocker.blogspot.com/

Anand, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response