This is a set of small programs in Basic-256, related to various topics.
Just copy,paste and run.
Note : Sometimes programs do not run in recent BASIC 256 versions.
Thursday, January 10, 2013
Normal Distribution
# Normal distribution simulation with mean=300 and standard deviation = 60
graphsize 600,600
sd=60
mean=300
dim bar(600)
for n = 0 to 99999
number = int(mean + sd*sqr(-2*log(rand))*cos(2*pi*rand))
No comments:
Post a Comment