The first problem we need to addresss is how we are going to display the sequence of lights which the player must repeat. We are going to use a row of LEDs attached to PORTA.
Each of the bits in PORTA will control one of the lights on the output. We have seen how each pin of an output port is controlled by a particular bit value in the numeric value which is held in that memory location.
On the right you can see this in action. The program first makes all the pins on PORTA into outputs. It then loads a sequence of values into PORTA, turning on the light attached to each. The first time you run the program you could see if you can guess which LED will light.