so guys i have done my code like this
void gotoxy(int x, int y) { COORD k = { x,y }; SetConsoleCursorPosition(GetStdHandle(STD_OUTPUT