03-04-2023, 03:46 PM
How do I clean an ARRAY?
I would like to use the function CLEAR.
I would like to use the function CLEAR.
Code:
VAR A(3) TYPE INTEGER
PROCEDURE CLEAR (v)
FOR i = ADDRESS(v) TO ADDRESS(v)+SIZE(v)-1
POKE i,0
NEXT i
END PROCEDURE
PROCEDURE Clean
CLEAR A
END PROCEDURE
PROCEDURE Test
LET A(1) = 1
PRINT A(1)
Clean
PRINT A(1)
END PROCEDURE