#include #include // int pomo_time = 1500; // int pomo_rest = 600; int pomo_time = 5; int pomo_rest = 3; int pomo_long_rest = 900; int pomo_count = 0; int is_break = 0; int pomo (int p_time, int p_rest, int p_count, int break_status) { if (!break_status) { if (p_time > 0 && p_count < 4) { printf("pomo: %d\n", p_time); sleep(1); p_time--; } break_status = 1; } return 0; } int main (int argc, const char * argv[]) { pomo(pomo_time, pomo_rest, pomo_count, is_break); // if (!is_break) { // while (pomo_time > 0 && pomo_count < 4) { // printf("pomo: %d\n ", pomo_time); // sleep(1); // pomo_time--; // } // is_break = 1; // printf("END POMO!\n"); // }; // if (is_break) { // while (pomo_rest > 0 && pomo_count < 4) { // printf("rest: %d\n ", pomo_rest); // sleep(1); // pomo_rest--; // } // is_break = 0; // printf("END REST!\n"); // }; return 0; }