[comp.unix.wizards] PRINTF CONSTRUCT

raj@ursa.UUCP (06/13/87)

I have often used the construct

        printf("%*s\n",i,"#");

to get '#' printed after i blank spaces.  For example, the following 
program could be used to get a plot of the sin function:


#include <math.h>
#include <stdio.h>
main()
{
int i,j=0;
while(1==1){
i = 40+38*sin((double) j++/10.0);
printf("%*s\n",i,"#");
}}


My question is:  Is this allowed in standard C, or am I dealing with
some non standard extensions?  I could not find this in Kernighan and
Ritchie.  But then it doesnt talk of enumerated types either.