I am trying to write a program that ask the user to input information for 10 cars and after that it outputs all the information he/she inputted on the screen.
The problem is, the loop I wrote seems not to work and the int outputCarInfo(); function never works.
Please help!
Edit: so I figured out why the loop doesn't work, which because of "return 0;" but I still don't know why the outputCarInfo() function doesn't work the way I want it to.
It doesn't like like you are calling it from main anywhere so it will never be ran.
Put outputCarInto(); at the end of your main function (before return 0).
Needs to be moved outside of the main function.
Also you should move the return 0 to the end of your main function not at the end of one run in your for loop. Then you need to call your output function in the main function and before the return statement.
TLDR: Move line 39 to 42 , move line 43-55 to 58 call output before the return statement