Ok I feel kinda stupid not being able to figure this out but here goes
I have a working on a program for a class and its my first time using arrays and i got the concept but the syntax is hurting me
the input requirements are
- using a loop, prompt the user to enter 5 salaries (ill come back to that later)
-store the salaries in the array (got that)
but its the processing requirements that got me stumped
-after all 5 salaries are input computer the social security tax on each and store in another array (this is what i dont know how to do)
-output the results (i can manage that)
I know thats not correct but its the best I can come up with at the moment..i have watched a few tuts on youtube and have gone over class not and my textbook. :( Any help would be great
I'll only comment on lines 17 - 22.
The assignment is asking for an array, so define ssTax as an array (float ssTax[5];)
There are five elements in your array, so why are you looping only through the first one (x < 5)
x'th element of ssTax equals 0.062* x'th element of salary. Do you see what's missing?([x])
oops. sorry about the x < 1. I was playing around with a dumb down version of the program to test if i had done the first array right and i forgot to change it back