(C PROGRAMMING ONLY) DO NOT EDIT THE MAIN 7. Special Exchanging Gifts by CodeChum Admin It's Christmas time and we're having this exchanging gifts activity! I want to surprise the receiver of my gift. After he/she receives my gift, I will add an additional P100 bill! Instructions: In the code editor, you are provided with a main() function that asks the user for 2 integers. Then, a function call to a function named, exchangeGift() is made and the addresses of the 2 integers are passed. This exchangeGift() function hasn't been implemented yet so this is your task. This has the following description: Return type - void Name - exchangeGift Parameters - 2 addresses of 2 integers Description - swaps the value of the 2 integers and then adds 100 to the 2nd integer (or 2nd parameter) DO NOT EDIT THE MAIN Input 1. First integer 2. Second integer Output Enter integer 1: 10 Enter integer 2: 20 20 110
(C PROGRAMMING ONLY)
DO NOT EDIT THE MAIN
7. Special Exchanging Gifts
by CodeChum Admin
It's Christmas time and we're having this exchanging gifts activity!
I want to surprise the receiver of my gift. After he/she receives my gift, I will add an additional P100 bill!
Instructions:
In the code editor, you are provided with a main() function that asks the user for 2 integers. Then, a function call to a function named, exchangeGift() is made and the addresses of the 2 integers are passed.
This exchangeGift() function hasn't been implemented yet so this is your task. This has the following description:
Return type - void
Name - exchangeGift
Parameters - 2 addresses of 2 integers
Description - swaps the value of the 2 integers and then adds 100 to the 2nd integer (or 2nd parameter)
DO NOT EDIT THE MAIN
Input
1. First integer
2. Second integer
Output
Enter integer 1: 10
Enter integer 2: 20
20 110
Step by step
Solved in 3 steps with 2 images