Is var short for variable?

Thus far, var sounds interesting, but mysterious


haha, yes var is the reserved keyword for variable. Similarly const is for constant.

Thanks Carolyn :blush:

yes, here is a nice example for the var keyword:

So why do we get “false false false”

1 Like

Because false is the zero value for bool.


No, it’s documented as such in the language specifications:

When I said intriguing, that meant I was interested, but a little lost. Your answer however was helpful. Don’t worry, I’ll get there

1 Like When I ran the program contained herein :sweat_smile: I got 0 false false false, Why is that?

Oops, I see I already asked that question. I’ll go over the answer again.

I understand very slightly better, but I’m still a bit lost here.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.