Use recursion:
factorial: t1 t1 = 0 ifTrue: [^ 1]. ^ t1 * (self factorial: (t1-1))
Offline
Thank you guys so much!
But I have one more question: Whenever I make a reporter or boolean, the little checkmark that can show or hide a variable appears. The display is glitchy--when you update the number, instead of updating, it shows a new one. How do you turn off the ability to show/hide the value?

Offline
Greenatic wrote:
Thank you guys so much!
![]()
But I have one more question: Whenever I make a reporter or boolean, the little checkmark that can show or hide a variable appears. The display is glitchy--when you update the number, instead of updating, it shows a new one. How do you turn off the ability to show/hide the value?
Scratch has a method for that.
Go to Scratch-Blocks > CommandBlockMorph > all > canBecomeWatcher
You're smart enough to know how to edit that
Offline
Thanks!

Offline