Array problem

BlitzPlus Forums/BlitzPlus Beginners Area/Array problem

The Forum Archive is locked. These are the original blitzbasic.com forums, kept so their posts can still be read and searched. No new topics, replies or edits can be made here. To join the conversation, head over to the Blitz3D+ forums.

Here's an interesting bit of info about using If statements with True and False operators. Coding something like:
If variable = False
Is the same as saying:
If variable = 0
Or:
If Not variable
Basically, False is equal to zero. True, on the other hand, can represent two different things. If you use it in this fashion:
variable = True
Then True will equal 1, and that value will be stored in variable. If, however, you use it like this:
If variable = True
Then True represents any value greater than 0. How you "phrase" your code doesn't usually make a difference to the output, it just makes it more or less compact. So, instead of:
If variable = False
Consider:
If Not variable
And instead of:
If variable = True
Consider:
If variable
That's all. Happy coding!