From 6d606e85f4ecf4070e3d985e94faa2de19ee4a0b Mon Sep 17 00:00:00 2001 From: lunarised Date: Mon, 11 Mar 2019 12:07:34 +1300 Subject: [PATCH] Fixed Inconsistency in grammar --- 99Bottles/C99Bottles.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/99Bottles/C99Bottles.c b/99Bottles/C99Bottles.c index 5b704af..a9d79ed 100644 --- a/99Bottles/C99Bottles.c +++ b/99Bottles/C99Bottles.c @@ -1,7 +1,7 @@ #include #include int rMethod(int _bottle){ - if(_bottle > 1){ + if(_bottle > 2){ printf("%d bottles of beer on the wall!\n", _bottle); printf("%d bottles of beer!\n", _bottle); printf("You take one down, and pass it around!\n"); @@ -10,6 +10,13 @@ int rMethod(int _bottle){ printf("\n"); rMethod(_bottle); } + else if (_bottle == 2){ + printf("%d bottles of beer on the wall!\n", _bottle); + printf("%d bottles of beer!\n", _bottle); + printf("Take it down, and pass it around!\n"); + _bottle--; + printf("%d more bottle of beer on the wall!\n", _bottle); + } else if (_bottle == 1){ printf("%d more bottle of beer on the wall!\n", _bottle); printf("%d more bottle of beer!\n", _bottle);