Anonymous user
Day of the week: Difference between revisions
→{{header|QL SuperBASIC}}: added output
(→{{header|QL SuperBASIC}}: added output) |
(→{{header|QL SuperBASIC}}: added output) |
||
Line 684:
==={{header|QL SuperBASIC}}===
<b>Works with:</b> [https://en.wikipedia.org/wiki/Sinclair_QL ''Sinclair QL''] <br>
...having a structured [https://en.wikipedia.org/wiki/SuperBASIC ''BASIC''] with MOD & DIV and quite unlike the ZX81's "zeroeth-generation" BASIC that's rather like using a calculator which
<lang basic>
Line 697:
LET i$=m%*256+ 19300 : n%=i$(2TO 3)+ d%
FOR count=S TO O
LET y$=count : w%=(y$(1TO 2)&"32"DIV 16+ count DIV 4+ count+ n%)MOD 7
REM or by using w%=(y$(1TO 2)&"16"DIV 16+ count DIV 4+ count)MOD 7 as further optimisation
▲ REM further optimisation beyond skipping irrelevant years below
IF w%=0 THEN PRINT count : count = count+ 4
END FOR count
Line 706:
{{keypress|ctrl|space}}
</lang>
=={{header|Batch File}}==
|