#include #include int main() { wchar_t path[MAX_PATH]; if (GetWindowsDirectoryW(path, MAX_PATH) != 0) { wprintf(L"Windows directory: %s\n", path); } else { wprintf(L"Error getting Windows directory.\n"); } return 0; }