blob: fb66e7a818ff0698301bd5ae2c105858a146bbd4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
//Example 1.12
N= 6;
disp(N,"total No. of possible outcomes (N)=");
M1= 3;
disp(M1,"No. of Favorable cases(an even number)=");
M2= 3;
disp(M2,"No. of Favorable cases(an odd number)=");
M3= 2;
disp(M3,"No. of Favorable cases(less than 3)= ");
M4= 1;
disp(M4,"No. of Favorable cases(a Six)=");
P1=M1/N;
P2=M2/N;
P3=M3/N;
P4=M4/N;
disp(P4,"Probab. of (a Six)= ",P3,"Probab. of (less than 3)=",P2,"Probab. of (an odd number)=",P1,"Probab. of (an even number)=");
|