Simulates how many rolls it takes for a d100 to roll a 100 Does this 200,000 times but it takes a while (I would do more but scratch's list has a limit of length 200,000) avg is the average (mean) amount of rolls it takes for a 100 median is the median amount of rolls it takes for a 100 totalTrials is the amount of rolls across all trials trialCount is the amount of rolls it takes for each trial, sortedTrialCount is this list but sorted ascending You can remove the sorting code & median code to reach 200,000 trials much faster
Inspired by Noll Reed & co.