Sunday , May 29 2022
Home / C / C #04 – Format Specifiers in C Language

C #04 – Format Specifiers in C Language

Format Specifiers

Format specifiers are the operators used in printf() function to print the data which is referred by an object or a variable. when a value is stored in a particular variable

Format specifier Characters matched Argument type
%c any single character char
%d, %i integer integer type
%u integer unsigned
%o octal integer unsigned
%x, %X hex integer unsigned
%e, %E, %f, %g, %G floating point number floating type
%p address format void *
%s any sequence of non-whitespace characters char
// file name P04.C
void main()
    int i=10;
    char c='A';
    float pi =3.14;



About Faheem

An adaptable and responsible Software Engineer, who enjoys working with computers and the opportunity to learn new skills and work with new technologies is particularly attractive to me.

Check Also

C #08 – Loops and For Loop in C Language

  Loop in C Language A loop statement allows us to execute a statement or …

Leave a Reply

Your email address will not be published.