Current location - Plastic Surgery and Aesthetics Network - Plastic surgery and medical aesthetics - Characteristics of output characters of printf and putcar functions
Characteristics of output characters of printf and putcar functions
Printf: a function that generates a print format.

Function return value:

The general form of printf function is:?

int? printf(const? Charles? * format, [parameter]); ?

In the table above, are we visually? Type "printf ("in C++ and you will see. ?

Explain that the printf function type is an integer and the return value is an integer value. ?

Its value is actually the number of characters output by the printf control. ? The printf () function actually outputs all parameters by character. According to the parameter 1(const? Charles? * format), it is not difficult for us to understand. ? For example:? int? Party A and Party B; ?

a = printf(" gelin \ n "); ? The value of //a is 6.

b=printf("the? Value? Yes? printf? Yes: %d ",a); ? The value of //b is 24.

printf("\n%d\n ",b); ? The above program will output:?

putchar:?

Output a character on stdout, which is used to output a character to the terminal.

Its general form is putchar(c)