[Solved]Ece 206 L Lab Exercise 8 C Programming Series Parallel Resistance Value Accumulation Using Q37241232
ECE 206/L LAB EXERCISE #8: C++ Programming Series and Parallel Resistance (Value Accumulation using Array) Prelab: Preliminary C++ Program Introduction The fundamental Laws in Electrical Engineering concerning resistance are: (1) Resistors connected in series: (2) Resistors connected in parallel: Tasks: Draw and code flowchart to calculate the resistance of resistors connected either in series or parallel, using array to store the resistance values. Assume that the program can handle up to 1000 resistors The flowchart must include the following 1. Prompt the user to select either the series or the parallel connection. 2. Prompt the user to enter each resistance of the resistors connected, and use a sentinel to indicate the end of the data. 3. Read (get) the value of each of the resistors until the sentinel is reached. 4. Calculate the total resistance 5. Output the resistance value according to format specified below 6. Avoid division by 0 Note: Your program shouldn’t ask users to enter the total number of resistors! The print output format of the resistance must satisfy the same requirement as described in Lab 6 with the following additional requirement: Print the total resistance followed by values of each resistor Examples: Display For series configuration: Total series resistance is 2.123KOhm for 3 resistors: 1000 Ohm, 1000 Ohm, 123 Ohm. Display For parallel configuration: Total parallel resistance is 500 Ohm for 2 resistors: 1000 Ohm, 1000 Ohm Show Instructor or Lab Assistant: Show well-documented and correct C++ program, and run output to verity that your program work as intended Show transcribed image text ECE 206/L LAB EXERCISE #8: C++ Programming Series and Parallel Resistance (Value Accumulation using Array) Prelab: Preliminary C++ Program Introduction The fundamental Laws in Electrical Engineering concerning resistance are: (1) Resistors connected in series: (2) Resistors connected in parallel: Tasks: Draw and code flowchart to calculate the resistance of resistors connected either in series or parallel, using array to store the resistance values. Assume that the program can handle up to 1000 resistors The flowchart must include the following 1. Prompt the user to select either the series or the parallel connection. 2. Prompt the user to enter each resistance of the resistors connected, and use a sentinel to indicate the end of the data. 3. Read (get) the value of each of the resistors until the sentinel is reached. 4. Calculate the total resistance 5. Output the resistance value according to format specified below 6. Avoid division by 0 Note: Your program shouldn’t ask users to enter the total number of resistors! The print output format of the resistance must satisfy the same requirement as described in Lab 6 with the following additional requirement: Print the total resistance followed by values of each resistor Examples: Display For series configuration: Total series resistance is 2.123KOhm for 3 resistors: 1000 Ohm, 1000 Ohm, 123 Ohm. Display For parallel configuration: Total parallel resistance is 500 Ohm for 2 resistors: 1000 Ohm, 1000 Ohm Show Instructor or Lab Assistant: Show well-documented and correct C++ program, and run output to verity that your program work as intended
Expert Answer
Answer to ECE 206/L LAB EXERCISE #8: C++ Programming Series and Parallel Resistance (Value Accumulation using Array) Prelab: Preli… . . .
OR

