summaryrefslogtreecommitdiff
path: root/1529/CH2/EX2.13/2_13.sce
blob: 5e1839376ea35eee3c70f35674de1b933220b92a (plain)
1
2
3
4
5
6
7
//Chapter 2, Problem 13
clc;
V=240;              //voltage
R=960;              //resistance
I=V/R;              //calculating current using Ohms law
P=V*I;              //calculating power
printf("Power rating P = %d W",P);