From 33ec05e766a0830d0698d3f406575d88874a2c1e Mon Sep 17 00:00:00 2001 From: TriantaTV Date: Thu, 29 Sep 2022 22:06:05 -0500 Subject: [PATCH] Fixed Eating Check --- DiningPhilosophers.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DiningPhilosophers.c b/DiningPhilosophers.c index 0043908..0483df1 100644 --- a/DiningPhilosophers.c +++ b/DiningPhilosophers.c @@ -60,7 +60,7 @@ int main(int argc, char* argv[]) bool AllPhilosophersFull(PhilosopherData PhilosopherList[], int numPhilosophers) { for (int i = 0; i < numPhilosophers; i++) - if (PhilosopherList[i].eatingCount != 2) + if (PhilosopherList[i].eatingCount < 2) return false; return true; }