answersLogoWhite

0

Arrays use a Base Pointer and an Index. They are calculated using the notation BP+IDX*Size, where IDX 0 is the first index location, and Size is the size of each element (at a hardware level, the size is determined by the register the data is loaded into). Languages that start array indexes at 0 use this hardware notation. Other languages start at 1 as a means of being "human friendly", since the zeroth location is the primary cause for developers going "out of bounds" on an array (they forget that the size of the array is one larger than the last index of the array).

User Avatar

Wiki User

13y ago

What else can I help you with?

Related Questions

What is the advantage of the indirect and indexed addressing mode?

The advantage of indirect and indexed addressing modes lies in their flexibility and efficiency for accessing data. Indirect addressing allows for dynamic memory access by using a pointer to the memory location, enabling easier management of data structures like arrays and linked lists. Indexed addressing, on the other hand, facilitates accessing elements within data structures by combining a base address with an offset, making it efficient for iterating through arrays and performing calculations with varying data sizes. Together, these addressing modes enhance program versatility and can lead to more efficient memory usage.


What is an example of a programming problem that would be difficult if not impossible to code without the use of arrays?

Matrix arithmetic calculations, which are very common in all fields of engineering, would be difficult to code without arrays.


Why does array index begins with 0 not with 1?

It is because array name implies its address and if you want to access first element of it pointer address logic is as below: Arrays first element address = array base address + 0 Arrays second element address = array base address + 1


Where are some large arrays located?

That's what & operator is good for: gives you the address of the variables.


What does a cell address as it applies to Excel 2010 do?

A cell address identifies a particular cell. It can be used in formulas to help in calculations. By using the cell address you can access the value in the cell.A cell address identifies a particular cell. It can be used in formulas to help in calculations. By using the cell address you can access the value in the cell.A cell address identifies a particular cell. It can be used in formulas to help in calculations. By using the cell address you can access the value in the cell.A cell address identifies a particular cell. It can be used in formulas to help in calculations. By using the cell address you can access the value in the cell.A cell address identifies a particular cell. It can be used in formulas to help in calculations. By using the cell address you can access the value in the cell.A cell address identifies a particular cell. It can be used in formulas to help in calculations. By using the cell address you can access the value in the cell.A cell address identifies a particular cell. It can be used in formulas to help in calculations. By using the cell address you can access the value in the cell.A cell address identifies a particular cell. It can be used in formulas to help in calculations. By using the cell address you can access the value in the cell.A cell address identifies a particular cell. It can be used in formulas to help in calculations. By using the cell address you can access the value in the cell.A cell address identifies a particular cell. It can be used in formulas to help in calculations. By using the cell address you can access the value in the cell.A cell address identifies a particular cell. It can be used in formulas to help in calculations. By using the cell address you can access the value in the cell.


What is the important of pointer in c programming?

It is accessing data by address.


Whether all devices accessing the internet have ip address?

yes


Why do you use ampersand symbol for arrays and not for a string?

You don't need to use ampersand for arrays; it's entirely optional even for strings (character arrays). This is because arrays will implicitly convert to a pointer at the slightest provocation. Thus for an array named X, you can either pass the array to a function as X, &X or &X[0], they all refer to the exact same address.


What is multidimentional array?

Arrays having more than one dimension is known as multi-dimensional arrays. Multi-dimensional arrays is also known as arrays-of-arrays.


What is a multidimentional array?

Arrays having more than one dimension is known as multi-dimensional arrays. Multi-dimensional arrays is also known as arrays-of-arrays.


What is a PHP function that can sort arrays by other arrays?

You cannot sort arrays by other arrays; that wouldn't make sense, anyway.


What is Difference between index register and stack pointer?

An index register contains an address that can be used during effective address generation, often along with an offset in the instruction or in another register. This is most useful when accessing elements of arrays or structures. A stack pointer is a specialized index register that points to a region of memory that can store temporary elements, in a last-in-first-out structure, such as return addresses, parameters, and local storage for function calls.