vc24

Author: Art-top
Category: Christmas Challenge
System:   ZX Spectrum
Language: Basic
Len source code: 94 bytes (spectrum basic inner text)
Len exe file:    119 bytes (image of tape record: 25 bytes of header + 94 bytes of code)
Len code only:   94 bytes

Instructions:
Install fuse (or some other zx spectrum emulator), drag and drop the vc24b.tap onto fuse.exe (or into running fuse window) for load, then press R (RUN) and then Enter for run programm.

Description:
At the beginning "gift bow" characters are printed.
In the main block of the program there are two loops: an outer one - for the Y counter
and an inner one - for the X counter. The current counters determine which character
should be printed.

Conditional expanded text of the program without optimizations and with comments:

PRINT TAB 8;"\O/":      // print "gift bow"
LET a$=" |-+":          // set of characters in string $s
FOR y=-9 TO 9:          // vertical cycle
       FOR x=-9 TO 9:  // horizontal cycle
               PRINT a$(1+(NOT SIN (ABS x *PI/9)+2*(NOT SIN (ABS y*PI/9));:
                       // calculates which character in order of character set to output and prints it on the screen
       NEXT x:         // next x
       PRINT:          // print line feed
NEXT y                  // next y

Comments:
It was very interesting.