Write a C++ program (with two arrays) to:

1. Read the student number (integer type) and the test scores (decimal number) from the keyboard and store the data in two separate arrays (provide a method to end the input); --- Your arrays should be able to provide a size of at least 50.

2. display the student numbers and scores in a two column format;

3. Sort the arrays according to test scores;

4. display the student numbers and scores in a two column format again but this time the data has been sorted.

Sample output:

Enter student’s number:
1
Enter student’s test score:
89
Do you have more students? (y/n)
y
Enter student’s number:
2
Enter student’s test score:
95
Do you have more students? (y/n)
y
Enter student’s number:
3
Enter student’s test score:
76
Do you have more students? (y/n)
n
You entered:
1 89
2 95
3 76
The list sorted by test scores:
3 76
1 89
2 95
Academic Honesty!
It is not our intention to break the school's academic policy. Posted solutions are meant to be used as a reference and should not be submitted as is. We are not held liable for any misuse of the solutions. Please see the frequently asked questions page for further questions and inquiries.
Kindly complete the form. Please provide a valid email address and we will get back to you within 24 hours. Payment is through PayPal, Buy me a Coffee or Cryptocurrency. We are a nonprofit organization however we need funds to keep this organization operating and to be able to complete our research and development projects.