/* Demonstration of printf formatting codes. */ #include <stdio.h> main() { /* Declaration Statements */ short n, m; printf("C45.C -> Examples of printf formatting codes\n"); /* Initializing variables */ n = 14; m = -27; /* Print variables */ printf("%5d%5d\n\n", n, m); printf("\t\t%5d\n\t\t%5d\n", n, m); return(0); } /* End of Program C45 */ /*OUTPUT :
C45.C -> Examples of printf formatting codes 14 -27 14 -27 */
Last modified: 21/07/97