11-01-2021, 09:12 PM
More precisely, Sinclair BASIC evaluates "x AND y" as follows:
And Boriel ZX Basic evaluates "x AND y" as follows:
You only notice the difference when x is neither 1 or 0.
Code:
x AND y results x, when y is not zero
X AND y results 0, when y is zero
And Boriel ZX Basic evaluates "x AND y" as follows:
Code:
x AND y results 1, when both x and y are not zero
X AND y results 0, when either x or y is zero
You only notice the difference when x is neither 1 or 0.