blob: 1720908dc28b864d92ed30bbe2f93f972fa24a4d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
clear
//Initialisation
r1=10 //resistance in ohm
r2=20 //resistance in ohm
r3=15 //resistance in ohm
r4=25 //resistance in ohm
//Calculation
r=r1+r2+r3+r4 //series resistance in ohm
//Result
printf("\n R = %d ohm",r)
|