#include <stdio.h>
#include <stdlib.h>
int main()
{
printf("%10dOK\n", 8888); //右对齐。数字宽度为10,若不足10,在左边补足空格
printf("%-10dOK\n", 8888); //左对齐。数字宽度为10,若不足10,在右边补足空格
return 0;
}

#include <stdio.h>
#include <stdlib.h>
int main()
{
printf("%10dOK\n", 8888); //右对齐。数字宽度为10,若不足10,在左边补足空格
printf("%-10dOK\n", 8888); //左对齐。数字宽度为10,若不足10,在右边补足空格
return 0;
}