[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

LOGO-L> Chessboard



Hello There,

That's my program for drawing a chessboard.

I'll appreciate comments to the program, as well as other solutions.

Thank's

[[Yehuda]]

===========================================
to main ; Chessboard
chess 128 4
end

to chess :size :level
if :level<1[stop]
repeat 4[draw]
setpc ifelse 0=remainder heading 180[12][1]
fill_it
setpc 6      ; lines color
end

to draw
fd :size rt 90
chess :size/2 :level-1
end

to fill_it
pu rt 45 fd 3 pd
fill        ; brown or blue
pu bk 3 lt 45 pd
end
===========================================

GIF image



Global SchoolNet Foundation - Linking Kids Around the World!
Copyright GSN - All Rights Reserved - Comments & Questions
Visit GSN's Global Schoolhouse for more exciting learning resources!
Search our Site - Home