Take Care of Those 2040 Printouts
As we all have discovered, to our sorrow, those printouts produced by the TS2040 printer are pretty fragile stuff. No paper has an unlimited life, of course, as witness the incredible lengths to which libraries go to try to protect their most valuable books, But your printer’s paper reminds one of the poet who wanted his epitaph to read “Here lies one whose name is writ in water”.
To begin with, the paper is temperature-sensitive. That’s how it works. So it goes without saying that exposure to heat or sunlight is going to impair its usability. For instance, I bought some rolls of the double-width Big Blue paper, with the intention of splitting them to fit the 2040 printer. A great bargain, but you should have seen what happened to the paper when I split it with my bandsaw. Luckily, that big black smear was out at the edge, where it doesn’t interfere with the printing. Paul Holmgren tells me that he got a noticeable discoloration just from using a hacksaw.
A Loser on a Loser
Serious bridge players recognize the value of the tactic of playing a loser on a loser. Suppose, for instance, that you (declarer) have a small diamond in your hand, and a small heart in dummy. Spades are trumps. At best, you’d like to take a trick with each of these small cards, either by trumping them or by leading them after your opponents have nothing left but clubs. But you can’t always manage things so neatly. The next best tactic, if you can arrange it, is to get rid of them both on the same trick, rather than losing a separate trick with each.
Similarly in programming. If you have two operations that take lots of time, see if you can arrange the program so that you can combine the delays of both operations, with a saving in overall delay. Or at least a saving in the frustration generated by the delay.
A principal cause for delay in computer operation is the response time of the human senses and muscles. Here’s a way that you can “bury” an unavoidable delay into that response time.
The program shown is a simple sort routine. The trick is that it sorts each number WHEN IT IS ENTERED, so the time of sorting tends to get lost in the time it takes to INPUT the number. Even in BASIC, which is not known for its high speed, the sort time is not detectable, unless you bury the new number way down below hundreds of numbers already in the array. If you used machine code, even that delay would be impossible to detect.
This technique also accommodates transcendental numbers, by the way, as well as fractions, negative numbers, and numbers expressed in engineering notation, such as 2E4.