conio.h and gotoxy does not work with my compiler for C. I tried searching for solutions on the web and found the following:
void gotoxy(int x, int y)
{
printf("\033[%d;%dH", y, x);
}
However, it does not position the cursor as intended. It only displays
←[1;10H
when I try to set x and y to 10 and 1 respectively. I have found other alternatives like using SetConsolePosition but I would still like to know if using ANSI escape sequences would work.
I am currently using the CodeBlocks IDE.