Question: 1. 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

1. 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 populatet 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 100 2 24 Average Power: 45 watts The power is the amps at a given hour times the voltage at the same hour Calculate the average power consumed for the day and display it at the end. i.e
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
