Answered step by step
Verified Expert Solution
Question
1 Approved Answer
EGR 126 Exercise 7A - for loops The objective of this Exercise is to gain experience with for loops by printing values counting forward and
EGR 126 Exercise 7A - for loops The objective of this Exercise is to gain experience with for loops by printing values counting forward and backward. Write a computer program with two for loops. Loop 1 Prints the values from 0 to 9 in increments of 1 Loop 2 Prints the values from 10 to 5 in decrements of 0.5 You do not need any input for this program. Only use for loops, do not use while, or do-while Your output should look something like the following: C:Windows system32\cmd.exe Harriette Roadman Exercise 7A. Using For Loops January 24. 2016 Counting forward by:1 0 1 23 4 5 67 89 Counting backward by 0.5 10 9.5 9 8.5 87.5 6.5 6 5.5 5 ress any key to continue _ Additional practice: How would you modify your program to print the following examples? 3 6 9 12 15 18 21 2.5 5 -7.5 10 -12.5 15 10 1001000 10000 100000
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started