#include <stdio.h>

const int DX[] = {-2,-2,-1,-1,1,1,2,2};
const int DY[] = {-1,1,-2,2,-2,2,-1,1};

void printMoves(int* moves, int length);

int main() {
    int moves[] = {2,3,1,5,7,0,0,3,2,5};
    printMoves(moves, 10);
    return 0;
}


void printMoves(int* moves, int length) {

    int x = 0, y = 0, i;

    for (i=0; i<length; i++) {
        x = x + DX[moves[i]];
        y = y + DY[moves[i]];
        printf("(%d, %d)\n", x, y);
    }
}
