-
Notifications
You must be signed in to change notification settings - Fork 0
cprintf
Thomas Foster edited this page Apr 15, 2021
·
1 revision
Function Writes formatted output to the screen.
Syntax int cprintf(const char *format, ...);
Prototype in conio.h
Return value cprintf returns the number of characters output.
See also putch, cputs
cprintf accepts a series of arguments, applies to each a format specification contained in the format string pointed to by format, and outputs the formatted data directly to the screen, to the current text window. There must be the same number of format specifications as arguments. For more information, see printf from the C Standard Library.
int value = 110;
cprintf("Decimal value %d is hex: %X, octal: %o, character: %c\n", value, value, value, value);