Printf
Code
\a : ベルを鳴らす \n : 改行 \t : タブ \x : 16進数 %c : 文字 %d : 整数 (10進数) %o : 整数 (08進数) %x : 整数 (16進数) %X : 整数 (16進数) %ld : Long Int 型 %f : 浮動小数点数 %p : ポインタ %s : 文字列
Sample
printf("08進数出力        :%o\n", dt);
printf("10進数出力         :%d\n", dt);
printf("16進数出力         :%x\n", dt);
printf("16進数出力         :%X\n", dt);
printf("Long Int           :%ld\n", ldt);
printf("固定少数点形式	   :%f\n", dd);
printf("科学表記形式	   :%e\n", dd);
printf("一般形式	   :%g\n", dd);
printf("文字列		   :%s\n", ss);
printf("ポインタ           :%p\n", &dt);
printf("10進数出力8桁右寄  :%8d\n", dt);
printf("10進数出力8桁右寄  :%08d\n", dt);
printf("10進数出力8桁左寄  :%-8d\n", dt);
printf("文字列8桁右寄	   :%8s\n", ss);
printf("文字列8桁左寄	   :%-8s\n", ss);
printf("固定小数点形式     :%10f\n", dd);
printf("固定小数点形式	   :%10.4f\n", dd);
printf("科学表記形式1      :%e\n", dd);
printf("科学表記形式2	   :%10.5E\n", dd);
printf("一般形式	   :%g\n", dd);
printf("符号付き	   :%+d\n", dd);
Acknowledgments
Daiphys is a professional services company in research and development of leading-edge technologies in science and engineering.
Get started accelerating your business through our deep expertise in R&D with AI, quantum computing, and space development; please get in touch with Daiphys today!
Daiphys Technologies LLC - https://www.daiphys.com/