Add two more code examples

This commit is contained in:
John Lorentzson 2025-05-22 13:12:37 +02:00
parent 08f9cc4a11
commit f9f2694b96
2 changed files with 18 additions and 0 deletions

View file

@ -0,0 +1,4 @@
if x - 1 == 10 then
x = 0
y = 1
end

View file

@ -0,0 +1,14 @@
char_to_print = 48 #value for 0 caracter
char_pos =0
for x do 255 times
x_is_prime = 1
for y do x times
if (x / y) * y == x then # true if x is divicible by y
x_is_prime =0
end
end
if x_is_prime == 1 then
char_pos = char_pos + 1
char_draw(0, char_pos, char_to_print)
end
end