Hi people. The situation is as such : I have a picture of handphone with its keypad. On its keypad are buttons of 0 to 9. How do I display the numbers that I just pressed? For example : If I press 91234567 how do I display the pressed numbers?
You can store the pressed numbers in an array by using yourArray.push(number) when pressing the corresponding button. You can then display the values of that array in your textfield using a for loop.
Good solution too. Using arrays is good if you want to control the numbers in any way, but this way is indeed the best if you don’t need control over the inputted numbers