Why is %c used in C?

Because %d will print the numeric character code of the char:

printf("%d", 'a');

prints 97 (on an ASCII system), while

printf("%c", 'a');

prints a.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)