C - Write program to align integer output

Requirements

Write program to align integer output

Demo

#include <stdio.h>
#include <ctype.h>

int main()/*from w ww.  ja  va2  s  .  c om*/
{
    int index;
    int alpha=123,blank=12,punct=3;

    printf("%4d alphabetic characters\n",alpha);
    printf("%4d blanks\n",blank);
    printf("%4d punctuation symbols\n",punct);

    return(0);
}

Result