**TI89**mainRdifpciT¥Zú() Prgm ClrIO Disp "1 = large, large","2 = large, finite","3 = finite, large","4 = finite, finite" Input c ClrIO If c=3 or c=4 Then Disp "1st population size" Input k Else 0k EndIf If c=2 or c=4 Then Disp "2nd population size" Input l Else 0l EndIf Disp "1st number of yes" Input m Disp "1st sample size" Input p Disp "2nd number of yes" Input n Disp "2nd sample size" Input q Disp "confidence level" Input r If k=0 Then ¨(m/p*(1-m/p))s Else ¨(m/p*(1-m/p))*¨((k-p)/(k-1))s EndIf If l=0 Then ¨(n/q*(1-n/q))t Else ¨(n/q*(1-n/q))*¨((l-q)/(l-1))t EndIf s\invNormF((r+1)/2,0,1)b b*¨(s^2/p+t^2/q)e ClrIO Disp "Difference, Error" Disp {round(m/p-n/q,4),"+-",round(e,4)} Disp "Confidence Interval" Disp {round(m/p-n/q-e,4),round(m/p-n/q+e,4)} EndPrgm äåÜé