|
!'Reverend Back's Abbey Floor
LET A$="01"
FOR I=1 TO 4
LET B$=A$&A$&REV$(A$)
LET A$=B$
NEXT I
LET L=LEN(A$)
DIM M(L,L)
FOR X=1 TO L
FOR Y=1 TO L
LET M(X,Y)=MOD(VAL(A$(X:X))+VAL(A$(Y:Y)),2)
NEXT Y
NEXT X
SET WINDOW 0,1,0,1
MAT PLOT CELLS, IN 0 , 0 ; 1 , 1 : M
END
EXTERNAL FUNCTION REV$(X$)
LET S$=""
FOR I=LEN(X$) TO 1 STEP -1
LET S$=S$&X$(I:I)
NEXT I
LET REV$=S$
END FUNCTION
|
|