**TI89**mainRexponen*¥ZÐ() Prgm ClrIO Disp "1 = left prob","2 = right prob","3 = middle prob" Input t ClrIO Disp "average" Input q If t=3 Then Disp "lower bound" Input j Disp "upper bound" Input k –^(­j/q)-–^(­k/q)b Else Disp "bound" Input k 1-–^(­k/q)b EndIf Disp "graph?" Input z If z=1 Then PlotsOff FnOff Define y1(x)=1/q*–^(­x/q) 0xmin max(3*q,k)xmax xmax/10xscl 0ymin 1/qymax ymax/10yscl If t=3 Then Shade 0,y1(x),j,k Else If t=1 Then Shade 0,y1(x),0,k Else Shade 0,y1(x),k,xmax EndIf EndIf EndIf ClrIO If t=3 Then Disp "probability =",b Else If t=1 Then Disp "left tail prob =",b Output 32,1,"(right tail)" Output 44,1,1-b Else Disp "right tail prob =",1-b Output 32,1,"(left tail)" Output 44,1,b EndIf EndIf EndPrgmäåÜÙÜ