INPUT "vvedite kol-vo elementov ", n
DIM a(n)
RANDOMIZE TIMER
FOR i = 1 TO n
a(i) = INT(RND * 20) - 10
NEXT
PRINT "ishodnyj massiv"
FOR i = 1 TO n
PRINT a(i);
NEXT
PRINT
FOR i = 1 TO n
IF a(i) < 0 THEN a(i) = 0 ELSE IF a(i) > 0 THEN a(i) = 1
NEXT
PRINT "novyj massiv"
FOR i = 1 TO n
PRINT a(i);
NEXT