Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
aceface3398y@620hun At first I thought this splitting hairs. And then I worked on code that used it interchangeably and we learned real fast that it REALLY matters
-
fredrf15248yAs @620hun said: the max index is 3. Therefore the number of elements is 4.
In this case, everyone would count 4 apples.
Why would one store those in an array if the purpose is to know the total number of apples anyway? -
fyroc58758y@FelisPhasma yes but it says "count by" not indexed by. The length is the count, how many elements in an array.. if you get the count aka the length, it will always be 4.
Related Rants
hip hip [ ]
sorry, couldn't help myself.
undefined
lame programmer puns
0 indexed
arrays