Current location - Plastic Surgery and Aesthetics Network - Plastic surgery and beauty - How to input and output the number of 10 through C language?
How to input and output the number of 10 through C language?
The programming ideas and methods of C language are as follows:

1. First, you need to define an integer array to store the entered 10 integers. The array a is defined here.

2. Then use the for loop to accept the integer 10 entered from the keyboard. I is used here as the cursor variable of the loop.

3. After input, use the for loop again to output ten numbers stored in the array in sequence. Here, the local variable I is also used as the cursor of the loop.

4. Then, use the for loop again to output the ten integers stored in the array in reverse order. Similarly, you still need a local variable as a loop cursor. (The method is roughly the same as sequential output)

5. After the code is written, click Run Program to see the final running result in the debugger window.