Article View: net.lang.apl
Article #35a problem and a solution
From: uwvaxgreg
Date: Thu, 06 May 1982 10:23
Date: Thu, 06 May 1982 10:23
17 lines
1122 bytes
1122 bytes
In a corner of an APL News special edition for the APL81 Conference, Jeff Shallit gives the following problems: find two expressions, each six characters or less, the first producing the vector 0 0 1 0 1, and the second producing 0 1 0 0 1. I am only able to come up with solutions that work in origin zero. Can anyone come up with solutions that work in origin 1, or better, solutions that are origin-independent? - Greg Johnson U Wis - Madison By the way, the solution I had in mind for the problem of sorting the rows of a matrix into lexicographic order involves decoding each row into a scalar quantity, sorting those scalars, and then re-expanding into a matrix. This solution assumes an arbitrary-precision machine, since for any large number L, a matrix containing the row 1, ( ceiling 2 log L ) rho 0 when decoded will require that the machine be able to represent a number larger than L.
Technical Details
Message-ID:
<anews.Auwvax.357>Path:
arc1-ca.pugleaf.net!utzoo!decvax!harpo!uwvax!gregShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!decvax!harpo!uwvax!greg From: uwvax!greg Newsgroups: net.lang.apl Subject: a problem and a solution Date: Thu, 06 May 1982 10:23:22 +0000 Message-ID: <anews.Auwvax.357>