Hello there .
I will make a project using 4 buttons and 16x2 LCD or (Serial Monitor). 1. button counts
2. produce button numbers. 3 buttons 1 button to see the number produced. 4 buttons 2. show the produced numbers.
Example: 1 will generate a number when the button is pressed Serial Monitor or 16x2 LCD 100, 101, 102. 3. When the button is pressed, the lcd will write on the screen sequentially. Press 100 then press 101.
Example: 200 will generate a number when button 2 is pressed Serial Monitor or 16x2 LCD , 201,202. 4. When the button is pressed the lcd will write on the screen sequentially. Printing 200 then printing 201.
I'm glad you wrote the code.