1 2 3 4 5 6 7
clc; //ex2.4 Vs=6; //volt Vd=0.7;//volt R1=10000;//ohm It=(Vs-Vd)/R1; //Total circuit current using kirchoff's volatage law disp('Ampere',It,"It=")