用C结合打印对帐单 [英] Combining Print Statements in C
本文介绍了用C结合打印对帐单的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我学习C,和我遇到了一些问题,让我写的(貌似)冗余code。我发现自己写code像
I'm learning C, and I am running into some problems which make me write (seemingly) redundant code. I am finding myself writing code like
printf("%c", someChar);
printf(" ");
这(因为它是在一个循环中)将输出类似
which (since it is in a loop) would output something like
a b c
有没有办法将这些打印语句结合?
Is there any way to combine these print statements?
推荐答案
只是写:的printf(%C,someChar);
请注意在%C
这篇关于用C结合打印对帐单的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文