Why not start off with a simplified version, whereby the number of moves per game is restricted to say 100, else failed attempt. Then you can easily get started with one-dimensional arrays.
Create your main loop zero to 499.
Initialize arrays to zero.
Start position row[0] = 3, col[0] = 2.
Create an inner loop one to 99.
Test direction.
Move accordingly, col[j] = col[j-1] + 1;
Test for boundary.
Test for successful attempt.
Print out number of failed attempts and successful sequence.