Answer to Question #313878 in C++ for Hassan

Question #313878

Declare a character array cArray of length 10.

• Input the values from user.

• Pass that array to a function copy using a pointer.

• Copy the values of cArray in c1Array using dereferencing.


1
Expert's answer
2022-03-18T07:50:19-0400

Here is program:

int main()
{
	const int size = 10;
	int* cArray = new int[size];
	int* c1Array = new int[size];
	for (int i = 0; i < size; i++)
	{
		cin >> cArray[i];
	}
	c1Array = cArray;


}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog