Question: I need help with a javascript assignment: 3. Average Power Write a program called average_power.js. We will simulate taking current and voltage readings from a
I need help with a javascript assignment:

3. Average Power Write a program called average_power.js. We will simulate taking current and voltage readings from a circuit and calculating the average power of the circuit. The program should create an array called volts and populate it with 24 random numbers between 5 and 20. Next create an array called amps and populate it with 24 random numbers between 1 and 10. These are your current readings for every hour for a given day. Compute the average power for each day and display it in a tabular format i.e Voltage Power 15 20 Hour Current 2 30 2 100 24 Average Power: 45 watts
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
