if else c++

#include <iostream>

int main() {
    int num;

    // Input
    std::cout << "Enter an integer: ";
    std::cin >> num;

    // Check if the number is positive, negative, or zero
    if (num > 0) {
        std::cout << "The entered number is positive." << std::endl;
    } else if (num < 0) {
        std::cout << "The entered number is negative." << std::endl;
    } else {
        std::cout << "The entered number is zero." << std::endl;
    }

    return 0;
}