Programming: Adding the 'x=' and 'y=' for the 'x' Cycling Though all of the LCD Cursor Locations

Modifying the program so that the xa nd y location values are shown on the LCD screen while the 'x' chasing character runs through all of the LCD cursor locations.



Structure: for () { for () { Code } } Example: for (int x = 0; x<3; x++) { for (int y = 0; y<3; y++) { //Print the x and y values } } If the values of x and y were printed, the output may look like this: 0, 0 0, 1 0, 2 1, 0 1, 1 1, 2 2, 0 2, 1 2, 2
Back to blog

Leave a comment

Please note, comments need to be approved before they are published.