Question: This assignment consists of five problems. Use the examples reviewed in class as a guide to develop the required pseudo-codes. Please upload a single document
This assignment consists of five problems. Use the examples reviewed in class as a guide to develop the required pseudo-codes. Please upload a single document to Canvas. Problem 1-20 points Write the pseudo-code of an algorithm that reads a list of numbers form the user and prints the numbe of zeroes in the list. As an example if the program reads X (1,0, 2,0,3, 0], the algorithm should print the number 3. Problem 2-20 points Write the pseudo-code of an algorithm that reads two lists of numbers form the user and prints "TRUE" if the lists are equal, and "FALSE" if not. Assume that both lists are of the same length. As an example if the algorithm reads X> [1, 0, 2, 0, 3, 0] andYs [1, 0, 3, 2, 3, 0], the algorithm should print "FALSE". Problem 3-20 points Write the pseudo-code bf an algorithm that reads a list of numbers containing the final grades of a given group of students in some course (on a 100-point scale). The algorithm should print a list with the corresponding letter grade for each student. As an example if the algorithm reads [93.2, 69.8, 78.3, 82.6, 95.1, 59.4), the output should be [A C, C, B, A, F. Problem 4 20 points Write the pseudo-code of an algorithm that reads a positive integer as an input and prints how many digits the input number has. For instance, if the user enters 234, the algorithm should print 3. Problem 5-20 points Write the pseudo-code of an algorithm that reads (1) a list X of length n, and (2) a list Y of length m s n. Assume that Y is populated with all different integers between O and n 1. The algorithm should print the surn of the elements in x with indexes li e.ndexed in . For instance, ifx-1.3 2.6.3 9 7 5 and Y [0,3, 6, 2) the algorithm should print .-X,-X-. #1-6 + 7 . 2-16
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
