这是我得到的错误......我错过了什么吗?我试图移动大括号,但它仍然不喜欢 else 语句
“else”之前的 91 语法错误
void admin_signIn(struct profile *puser)
{
int i=0;
char input[20];
strncpy( puser->UserName, "password", strlen("admin")+1 );
strncpy( puser->Pwd, "password", strlen("password")+1 );
for(i=0;i<3;i++)
{
printf("Enter admin user name:");
fgets(input,10,stdin);
rewind(stdin);
printf("Enter admin password:");
fgets(input,10,stdin);
rewind(stdin);
if(strcmp(puser->UserName,input) && strcmp(puser->Pwd,input));
{
printf("the user name is good");
}
admin_menu(puser);
else
{
printf("try again");
}
}