判断输入字符串是否和要求相等
错误示范:
char input[20] = {0};
if("abcdef"== input)
......
正确示范:(使用strcmp()函数)
char input[20] = {0};
if(strcmp(input,"abcdef") == 0)
......
判断输入字符串是否和要求相等
错误示范:
char input[20] = {0};
if("abcdef"== input)
......
正确示范:(使用strcmp()函数)
char input[20] = {0};
if(strcmp(input,"abcdef") == 0)
......