125k views
0 votes
How can the function anotherFunc change the contents of the second element of myints?

a)myints[2] = something

b)*myints [2] = something

c)myints [2] = & something

d)myints [1] = something

User Latesha
by
4.9k points

1 Answer

7 votes

Answer:

d)myints [1] = something.

Step-by-step explanation:

The elements in the array are stored serially.Every element in the array is indexed and the indexing start form 0 to size-1.So to access the second element in the array it's index will be 1.So to access the second element we have to write arrayname[1];

In our case the name of the array is myints.

Hence the answer is myints[1]=something

User Ffritz
by
6.3k points