Consider the following function:

void reverse(char * string1, const char * string2)
{
int stringsize = sizeof(string1)/sizeof(char);

*(string1 + stringsize – 1) = '\0';
string1 = string1 + stringsize – 2;

for (; *string2 != '\0'; --string1, ++string2) {
*string1 = *string2;
}
}
What method does the function use to refer to array elements?
a) array/subscript notation
b) array/offset notation
c) pointer/subscript notation
d) pointer/offset notation

d) pointer/offset notation

Computer Science & Information Technology

You might also like to view...

One likely cause of slow performance by a computer is a(n) ________

A) inexpensive processor B) slow keyboard C) insufficient amount of RAM memory D) complicated software application program

Computer Science & Information Technology

Explain how you ensured that an order cannot be placed if there are not enough items in inventory

What will be an ideal response?

Computer Science & Information Technology