#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#define MAX 10
int main()
{
char str[MAX];
int i=0;
int count=6;
int strIndxe=-1; //记录要删除该数字的下标
char Seachstr[MAX];
printf("请输入6个字符:");
for(i=0;i<count;i++)
{
scanf("%d",&str[i]);
}
for(i=0;i<count;i++)
{
printf("%d\n",str[i]);
}
//查找要删除的数字
printf("请输入要删除的字符:");
scanf("%d",&Seachstr);
for(i=0;i<count;i++)
{
if(strcmp(Seachstr,str(i)==0)) //弄不清楚错哪里!
{
strIndxe=i;
}
}
printf("为%d",strIndxe);
}
//提示“27 23 E:\xf\del_add.c [Error] called object 'str' is not a function or function pointer” 求大神解惑