Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
14
Task/Sierpinski-triangle/BASIC256/sierpinski-triangle.basic
Normal file
14
Task/Sierpinski-triangle/BASIC256/sierpinski-triangle.basic
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
clg
|
||||
call triangle (1, 1, 60)
|
||||
end
|
||||
|
||||
subroutine triangle (x, y, l)
|
||||
if l = 0 then
|
||||
color blue
|
||||
text (x, y, "*")
|
||||
else
|
||||
call triangle (x, y + l, int(l/2))
|
||||
call triangle (x + l, y, int(l/2))
|
||||
call triangle (x + l * 2, y + l, int(l/2))
|
||||
end if
|
||||
end subroutine
|
||||
Loading…
Add table
Add a link
Reference in a new issue