(11C) Code guessing game
|
05-31-2020, 07:43 PM
Post: #18
|
|||
|
|||
RE: (11C) Code guessing game
(07-23-2018 01:14 AM)Thomas Klemm Wrote: This program is based on Donald Knuth's paper The Computer as Master Mind. I read with interest all your interventions in all your posts for this thread. Thanks for the link, Thomas Klemm. So, I propose to everyone, the program I wrote for the HP11C. Be assured, this is one of my achievements that I did not do in one step. This program indeed required several phases spread over several calculators. One of my last versions, among the most successful, was intended for the HP12C and works without the use of the indirect addressing mode on the registers. I note with pleasure (and I reassure myself) by noting that my successive versions were indeed in accordance with the principles formulated in the document published by Donald E. Knuth. So, this version gives the possibility to choose the size of the code to find (4 or 5 digits, for example) and the number of distinct colors that can be used (from 1 to 9) to compose the code. Here is how to use it : On LBL A, you choose the number of digits in the code : 4 or 5 On LBL B, you give the number of colors : 6 or 9 On LBL C, you enter the number of authorized trials before the calculator reveals the code if you have not yet discovered it (usually 6 or 12, but personally I choose 99) Compose GSB D to prepare the code Key in 4 or 5 digits and press GSB E (or R/S) to examine a proposition The return format is c1c2c3c4c5.BW where c1c2c3c4c5 is your try, B the number of Black positions and W the number of White positions Code:
Example of use : 0.123 STO f RAN# GSB D --> 5.00 (see RCL 1 with 26829) 22689 R/S (or GSB E) --> 22689.23 22222 R/S --> 22222.20 26829 R/S --> 26829.50 x ↔ y --> 3.00 so you win in 3 tries !! |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 3 Guest(s)