SEARCH

SEARCH BY CITATION

A line of Minitab code was inadvertently omitted from the TECHNOLOGY TIP on p. 70 of the previous issue, 33(3). In particular, the line let k4 = k4 + (k5=1) was omitted from the last line of the file lottery.txt. For completeness, all of the Minitab code is listed below. After executing lottery driver.txt the displayed value of k6 will be an estimate of the chance of consecutive winning numbers in a 5/50 lottery. For further details, see the TECHNOLOGY TIP on p. 82 of 33(3).

lottery driver.txt:

let k1 = 1000

let k2 = 5

let k3 = 50

set c1

1:k3

end

let k4 = 0

execute 'c:\lottery.txt' k1

let k6 = k4/k1

print k6

lottery.txt:

sample k2 c1 c2;

noreplace.

sort c2 c2

differences 1 c2 c3

let k5 = min(c3)

let k4 = k4 + (k5=1)