Current location - Plastic Surgery and Aesthetics Network - Plastic surgery and medical aesthetics - What do %d and %c stand for when C language is output?
What do %d and %c stand for when C language is output?
When outputting in C language, %d and %c are conventions for formatting strings. %d stands for integer format, while %c stands for character format.

Common output format types:

%hd, decimal signed short integer

%d, decimal signed integer

%ld, decimal signed long integer

%hu, decimal unsigned short integer

%u, decimal unsigned integer

%lu, decimal unsigned long integer

%c, character type

%s, string type

%f, decimal floating-point type

%lf, decimal double-precision floating-point type

%e, scientific symbol format

%x, hexadecimal

%o, octal

%p, pointer in hexadecimal form

%%, output "%"character