%u改成%d试试
printf("%d",N)
或者直接改成这样
#include <stdio.h>
int main()
{
int N;
scanf("%u", &N);
while (N > 0)
{
printf("%u",N);
putchar('\n');
N--;
}
return 0;
}
#include <stdio.h>
int main()
{
int N;
scanf("%u",&N);
while (N>0) {
printf("%d",N);
putchar('\n');
N--;
}
return 0;
}