x=c(41,42,47,41,54,26,26,65,34,49,29,50)
mu0=50
alpha=0.05
n=length(x);n
s=sd(x);s
xbar=mean(x);xbar
t_compute=(xbar-mu0)/(s/sqrt(n));t_compute
sig_1_tailed=1-pt(abs(t_compute),n-1);sig_1_tailed
sig_2_tailed=2*sig_1_tailed;sig_2_tailed
critical_t=qt(1-alpha/2,n-1);critical_t
