#include #include #include using namespace std; int main () { //Get the current hour of the day (0 to 23 inclusive) time_t t {time(nullptr)}; tm *p {localtime(&t); if (hour >= 12) { if (hour < 12 + 5) { cout << "Good Afternoon."; } else if { cout << "Good evening."; } else if { cout << "Good night."; } else { cout << "Good Morning."; } cout << "\n"; return EXIT_SUCCESS; }