17 lines
377 B
Plaintext
17 lines
377 B
Plaintext
global bsd
|
|
global ms
|
|
print "Num ___Bsd___";chr$(9);"__Ms_"
|
|
for i = 1 to 10
|
|
print using("##",i);using("############",bsdRnd());chr$(9);using("#####",msRnd())
|
|
next i
|
|
|
|
function bsdRnd()
|
|
bsdRnd = (1103515245 * bsd + 12345) mod (2 ^ 31)
|
|
bsd = bsdRnd
|
|
end function
|
|
|
|
function msRnd()
|
|
ms = (214013 * ms + 2531011) mod (2 ^ 31)
|
|
msRnd = int(ms / 2 ^ 16)
|
|
end function
|