Computer Science Canada

Turing source program request

Author:  Light [ Thu Jan 13, 2005 4:25 pm ]
Post subject:  Turing source program request

had the source program last year, but now don't have the program anymore~
just wondering whether if anyone still have the program where there is a chart with different colors and with the number of the colors~since i am doing comp engineering related turing, and too tiring of testing which color works the best for the program~

Author:  Neo [ Thu Jan 13, 2005 4:35 pm ]
Post subject: 

This is what your looking for?

code:

var xm, ym, bm : int
var x := 0
var y := maxy - 50
for i : 0 .. 255
    drawfillbox (x, y, x + 25, y + 25, i)
    drawbox (x, y, x + 25, y + 25, black)
    x += 25
    if x > 25 * 20 then
        x := 0
        y -= 25
    end if
end for
loop
    mousewhere (xm, ym, bm)
    locate (1, 1)
    put "colour:", whatdotcolour (xm, ym), "          "..
end loop


: