Using only two dictionaries, stdio.h and string.h, I am writing a program in which the user must type "quit" (case insensitve) to quit the program. This is homework but I have searched the internet for something similar to my question but all I could find were if statements comparing strings, which is not my issue.
Code:
while((strcmpi(input, "quit") != 0))
{
//do stuff
}
The code above is what I have now but I'm almost sure that isn't right. I've already learned that strcmp and strcmpi return an integer 0 if the strings you're comparing are equal. But I have not learned how to asses if one string is not equal to another, let alone if you can even compare strings in the while loop parameter. This is not my entire assignment either, it is just a very small part. Everything I'm writing inside of the loop is the main part of the assignment so I am not asking anyone how to do my entire assignment. I would appreciate if someone could just steer me in the right direction. Thank you