Quantcast
Channel: stardot.org.uk
Viewing all articles
Browse latest Browse all 2528

8-bit acorn software: other • Re: A superfast 3D maze shooter for the PDP-11

$
0
0
Of course, you can also do:
divide by 100
save remainder
jsr prdecimal
print "."
pop remainder
if <10, print "0"
jsr prdecimal

...which can be more efficient if you've already got a generic divide subroutine or a specific divide-by-10 subroutine in the program.
Thank you. The prdecimal procedure is very good for the common case but the printsec procedure is specialized for the task and this makes its code slightly faster and smaller than based on prdecimal. ;)

Statistics: Posted by litwr — Sat Oct 26, 2024 7:13 am



Viewing all articles
Browse latest Browse all 2528

Trending Articles