Please help me, The question is:
"Write a program to accomadate 10 integers. Print the variables at position 3,5 and 2 respectively."
thank you!

int numbers[10];
for(int i=0; (i<10); i++)
{
  cout << "Please enter number " << i << endl;
  cin >> numbers[i];
}

cout << numbers[3];
cout << numbers[5];
cout << numbers[2];

Something like that?

int numbers[10];
for(int i=0; (i<10); i++)
{
  cout << "Please enter number " << i << endl;
  cin >> numbers[i];
}

cout << numbers[3];
cout << numbers[5];
cout << numbers[2];

Something like that?

Try not to spoon-feed him homework help considering he hasn't posted any attempts.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.