作业帮 > 综合 > 作业

c语言输出1-10,用for循环

来源:学生作业帮 编辑:搜搜做题作业网作业帮 分类:综合作业 时间:2024/04/29 17:03:43
c语言输出1-10,用for循环
Write a C program that outputs to standard out the numbers from 1 to
10 with comma separation using a 'for' loop.This list of numbers should be on a
single line (put a newline character at the end of the line).Place your answer in the
file called 'count.c' in the Q3 directory.When run from the command line you should
see:
$ ./count
1,2,3,4,5,6,7,8,9,10
$
c语言输出1-10,用for循环
希望有帮助
#include
int main(){
for(int i = 1; i