Matlab While loop to blink led

hey everyone, im sorry for asking this question but i made a tic tac toe project for college with arduino and i assigned X to light a led continuously and O to blink the led. but i dont know how to make it blink until we win the game or its drawn. i dont know how to use the while loop or for loop for this.
I have attached the code too.

ada.txt (6.71 KB)

i dont know how to use the while loop or for loop for this.

Don't use either. Let the loop() function do what its name implies and loop

Each time through loop() check whether it is time to change the state of the LEDs by comparing millis() and the value from millis() saved when the current state was entered. If it is time then change the state and save the millis() value. If no then carry on round loop() again doing what you need to such as reading inputs.

This is known as the BlinkWithoutDelay principle and there is an example in the IDE with that name. For an extended version look at Several things at the same time

Is this a Matlab or an Arduino question ?
The code that you posted certainly will not compile on an Arduino.