During a loop (for loop), say the user inputs a number and the loop repeated itself the number of ti.es the user inputed. During these repeats, the user inputs more data. How do I use every individual piece of data? For EXAMPLE, say the program asks a teacher to input the number of tests she has to grade. She says 5, it runs 5 times asking to input the grade, she puts 100, 90, 85, 76, 80. How would I add all these grades together for maybe an average?
It's probably something simple since I'm a beginner, nothing too fancy
you could just create a variable called total or something and have a variable average where all the grades added up in total are then divided by number of tests.
i cant figure out my project right now so here's how you'd do yours: