What does the return 0 block does

It’s fine. I’m just starting 8th grade on the second week so I wouldn’t know about the whole math thing

The only time I use math is when I watch the arcade advance or pick random or that calculator I made

The only time I used + - / or x

Okay, you know these blocks?

Not the first one or the third one. I forgot what the 4th one did tho

They are all functions, just like the ones you define yourself with the dark blue blocks.

Except Arcade has already defined them for you

And see how they are oval shaped?

Yes that is true

That means it returns something, like how the pick random function gives you a random number

Oh and like how the 2+2 returns you a 4?

Yes, but no.
That’s a complicated one, because it’s an expression. But it acts and looks like a function in blocks, so yeah

I was close wasnt I

Yes. I was confused between the difference of functions and expressions for a long time. There essentially the same, except the expression has no parenthesis when you use text based languages like Python or Typescript

image
That means this returns a number as in 0 in the picture

1 Like

If you put that in a function, it will give a 0 if that statement is run.
So yes!

But then where does 0 go to?

Let me do some blocks for a sec…

sorry that this is taking a long time

No problem!

Say we have this function: