I have a problem in running this Applet code.

I have made a TIC TAC TOE game using Applet.
I have a problem in this when I scan the position of the
element on the console everything vanishes from the screen.
I have tried using a array instead but it doesnt give
real time feeling of the game.My scanning is in form of
integers like 13 for 1st row and 3rd column.