#include<stdio.h>
int main(){ int a[10]; int n = 0, i; char ch=0; while (ch != '\n'){ scanf_s("%d",&a[n]); ch = getchar(); n++; } for (i = 0; i < n; i++) printf("%d ", a[i]); printf("\n"); return 0;}本文共 255 字,大约阅读时间需要 1 分钟。
#include<stdio.h>
int main(){ int a[10]; int n = 0, i; char ch=0; while (ch != '\n'){ scanf_s("%d",&a[n]); ch = getchar(); n++; } for (i = 0; i < n; i++) printf("%d ", a[i]); printf("\n"); return 0;}转载于:https://www.cnblogs.com/changyaoguo/p/5858018.html