Question: Question 5: Draw the flowchart for the following pseudocode 1. Initialize variables for even count, odd count, even sum, odd sum, and input number. 2.

 Question 5: Draw the flowchart for the following pseudocode 1. Initialize

Question 5: Draw the flowchart for the following pseudocode 1. Initialize variables for even count, odd count, even sum, odd sum, and input number. 2. Set the values of even count, odd count, even sum, and odd sum to 0 . 3. For i from 1 to 20 , do the following: a. Read the input number. b. If the input number is even, add it to the even sum and increment the even count. c. If the input number is odd, add it to the odd sum and increment the odd count. 4. Calculate the average of even numbers by dividing the even sum by the even count. Print the count and average of even numbers. 5. Calculate the average of odd numbers by dividing the odd sum by the odd count. Print the count and average of odd numbers

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!