So I'm working on an assignment for my Intro to C++ and as a disclaimer, I'm asking that you do not post your code or script of the solution, as I would like to solve it myself. I'm only asking if maybe someone could clarify what this assignment is asking for me to do. It sounds as if the two tasks are unrelated, so that's what's throwing me off. Down below is what the assignment is asking me to code.
COP 2200 Introduction to C
Homework 5
Feng-Hao Liu
In this assignment, you are going to turn in a single cpp le.
Task 1: Write a function \sort4" that returns void and takes inputs 4 integer pointers. The
function is going to sort the four integers pointed by the pointers.
Task 2: Write a function that returns void and takes inputs 6 integer variables x1; y1; x2; y2; x3; y3
and 2 integer points px; py. The function sets the value pointed by px as x1 +x2 +x3 and the value pointed by py as y1 + y2 + y3.
If the above is the sentence which makes you think the two exercises should be related, my guess is that it only means:
"in the same *.cpp file you need to write 3 functions:
- main();
- one which performs task 1;
- one which performs task 2.
These last two functions will be called by main()".