summaryrefslogtreecommitdiff
path: root/3769/CH17/EX17.31/Ex17_31.sce
blob: 6fa0a515c97ee1ef62e7c4504854755362afefab (plain)
1
2
3
4
5
6
7
8
9
10
11
12
clear
//Given
f1=20.0              //cm
f2=-40.0                //cm

//Calculation
f=1/((1/f1)+(1/f2))
P=1/f

//Result
printf("\n Focal length is %0.3f  cm", f)
printf("\n Power is %0.3f  D",P*10**2)