Sim = function(GoodGuys,BadGuys,Possesions,PointsGained){
test1 = shapiro.test(GoodGuys)
test2 = shapiro.test(BadGuys)
GoodGuys2 = round(rnorm(1000000, mean = mean(GoodGuys) + (Possesions * PointsGained), sd = sd(GoodGuys)))
GoodGuys1 = round(rnorm(1000000, mean = mean(GoodGuys), sd = sd(GoodGuys)))
BadGuys1 = round(rnorm(1000000, mean = mean(BadGuys), sd = sd(BadGuys)))
wins1 = 0
overtimes1 = 0
loses1 = 0
for (i in 1:1000000){
if (GoodGuys2[i] > BadGuys1[i]){
wins1 = wins1 + 1} else if (GoodGuys2[i] == BadGuys1[i]){
overtimes1 = overtimes1 + 1} else {
loses1 = loses1 + 1}
}
wins2 = 0
overtimes2 = 0
loses2 = 0
for (j in 1:1000000){
if (GoodGuys1[j] > BadGuys1[j]){
wins2 = wins2 + 1} else if (GoodGuys1[j] == BadGuys1[j]){
overtimes2 = overtimes2 + 1} else {
loses2 = loses2 + 1}
}
options(scipen=999)
summary = c(wins1/1000000,wins2/1000000,test1$p.value,test2$p.value)
summary
}