Log in

View Full Version : The following function will work with any size integer array. Void functio


amrelgohary
May 14, 2010, 12:20 PM
The following function will work with any size integer array.

void function1(int array[ ], int numElements);

amrelgohary
May 14, 2010, 12:21 PM
The following function will work with any size integer array.

void function1(int array[ ], int numElements);

amrelgohary
May 14, 2010, 12:24 PM
Given the following function definition,
void shift(int& a, int&b)
{
a = b;
b = a;
}
what is the output after the following function call?
int first = 0, second = 10;
shift(first, second);
cout << first <<" "<< second << endl;

amrelgohary
May 14, 2010, 12:26 PM
Given the following function definition,
void shift(int& a, int&b)
{
a = b;
b = a;
}
what is the output after the following function call?
int first = 0, second = 10;
shift(first, second);
cout << first <<" "<< second << endl;