Discuss Scratch
- Discussion Forums
- » Advanced Topics
- » ZZ Documentation (programming language built inside of Scratch)
- ez28quick
-
Scratcher
1 post
ZZ Documentation (programming language built inside of Scratch)
How does the ‘abs’ function work?
- ninjaMAR
-
Scratcher
1000+ posts
ZZ Documentation (programming language built inside of Scratch)
How does the ‘abs’ function work?Please make a new topic in Questions about Scratch. Abs turns a negative number to a positive number
Last edited by ninjaMAR (March 17, 2021 18:27:57)
- kkidslogin
-
Scratcher
1000+ posts
ZZ Documentation (programming language built inside of Scratch)
While and loop are both not in ZZL for some reason…Is it possible to make “Guess the Number” game?
It should be but I think Scratch 3.0 may have broken while. Then again, maybe I coded this wrong? I checked with a simpler program and it didn't work though so…sto rnd randint 1 10; sto rsp ""; sto a 0; while { not equal rcl rnd rcl a } { input join rcl rsp "Enter your guess:"; if { less rcl rnd ans } { sto rsp "Too high." } { if { great rcl rnd ans } { sto rsp "Too low." } {} }; sto a ans }; output "You got it."
- krm111
-
Scratcher
1 post
ZZ Documentation (programming language built inside of Scratch)
hey could you add clear function I think it would be very useful 
Edit: sorry didn't realize his was a old thread

Edit: sorry didn't realize his was a old thread
Last edited by krm111 (Sept. 3, 2023 00:27:51)
- luc1452
-
Scratcher
15 posts
ZZ Documentation (programming language built inside of Scratch)
I think that instead of having a ask block:
You could implement a simple typing script as so:
add all the letters you want to be able to type in the list “letters”.
and then your done.
this method is not the best but it gets the job done.
ask [] and waitwhich is just a bubble
You could implement a simple typing script as so:
when green flag clicked
set [i v] to [1]
forever
if <key (item (i) of [letters v] :: list) pressed?> then
set [answer v] to (join (answer) (item (i) of [letters v] :: list))
end
change [i v] by (1)
if <(i) > (length of [letters v] :: list)> then
set [i v] to [1]
end
end
add all the letters you want to be able to type in the list “letters”.
and then your done.
this method is not the best but it gets the job done.
Last edited by luc1452 (July 10, 2025 14:16:37)
- Discussion Forums
- » Advanced Topics
-
» ZZ Documentation (programming language built inside of Scratch)




