Mega Code Archive
Categories
/
C
/
Code Snippets
Printf output char, float and double
#include
int main(void) { char ch; float f; double d; ch = 'X'; f = 13.23; d = 18.09; printf("ch = %c, ", ch); printf("f = %f, ", f); printf("d = %f", d); return 0; }