c语言向一个已经排好序的数组中插入一个整数,保持原来的顺序不变

日期:2017-12-11 17:31:03 人气:1

c语言向一个已经排好序的数组中插入一个整数,保持原来的顺序不变

#include void main(void) { int str[10] = {1,2,3,4,5,6,7,8}; int temp1,temp2,*q,*p = str; for(;p<str+8;p++) printf("%d ",*p); printf("\n请输入要插入的数据:"); scanf("%d",&temp1); printf("请输入插入地方的数据(左插):");
    A+
热门评论