From this moment on, most people will have the holidays at the end, leaving aside, at least in part, games and entertainment, and we will start again.
The purpose of the program that we offer you in this issue is to work the writing of the numbers. It is relatively simple in terms of use, but this does not mean that it is not useful. We consider it interesting for children who are studying numbers and for those who are learning Basque.
The program gives the number in letter and you have to write the number. However, once practiced a little, the user can complete more things if desired. To do this, it is enough to make a small change in the program, so that it, instead of giving the written number, give the figure leaving it to be written in letter for the user.
As always, we leave these little changes in your hands. We attach a brief explanation of the main programs and parts.
(Note: To see the image go to pdf).Description of the program:
Four main tables are used in this program:
OAL: It is used to save the digits of the randomly created number.
The tables TAU1$, TAU2$ and TAU3$ are used to complete the representation in letter of the number. The digits that make up the number as an index will be used to access the elements of the following tables
...The most important part of this program is the subroutine NUMBER, which will be the one we will analyze most closely.
It uses as parameter X and Y (of the integer digit to which you should treat) and returns ZE$.
This subroutine deals with the number of three digits; the main program will take care of the millions, thousands, etc. Check that they are.
X and Y will be equal (in the case of a single digit number) or X Y. In the first case it is enough to take as index the digit located in the position X and take the value of the table TAU1$.
In the second case, the digits will be analyzed individually:
To establish the relationships between the words corresponding to each digit, the following criteria is followed:
NOTE
When capturing the tables TAU1$ and TAU3$, the value of the indices is 1 higher than the digit or number. The reason is that the first element of these tables is empty (for the case of 0).