From 094787db0b5fec8e69a962781af159b16d3a68f7 Mon Sep 17 00:00:00 2001 From: ItsBree <31864097+ItsBree@users.noreply.github.com> Date: Thu, 12 Oct 2017 13:58:20 -0500 Subject: [PATCH] Bree Gateley I have fixed you --- ThreeDigit.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/ThreeDigit.cpp b/ThreeDigit.cpp index 9caf505..f45cc89 100644 --- a/ThreeDigit.cpp +++ b/ThreeDigit.cpp @@ -34,6 +34,7 @@ void pause() { // MAIN void main() { + for (int i=0; i<30; ++i){ //allows to be inputted/repeated up to 30 times int number; // X is a three digit number int digit_a; // hundreds place int digit_b; // tens place @@ -45,26 +46,25 @@ void main() { digit_b = (number % 100) / 10; digit_c = number % 10; - if (digit_a > digit_b && digit_b > digit_c) { - cout << "descending"; + if (digit_a > digit_b && digit_b > digit_c) { + cout << number << " is descending." << endl; //if descending prints out } else if (digit_a < digit_b && digit_b < digit_c) { - cout << "ascending"; + cout << number << " is ascending." << endl; //if ascending prints out } else { - cout << "neither"; + cout << number << " is neither." << endl; //if neither prints out } - -pause(); + } pause(); // pauses to see the displayed text -} \ No newline at end of file +}