Типичная ошибка

Поток управления / Условные операторы / Операторы if/else

int latitude = 45;
const char *location = "not at the Equator";

//the condition must be in parentheses:
//if latitude == 0 { //<- Error: expected '(' before 'latitude'

//a single = assigns instead of comparing:
//latitude becomes 0, and 0 is false;
//the compiler only warns about it (with -Wall)
if (latitude = 0) {
    location = "Equator";
}
//latitude is 0
//location is "not at the Equator"

printf("latitude is %d\n", latitude);
printf("location is %s\n", location);