From d8e54349d30eac7311229afbbb4c6761e0428b76 Mon Sep 17 00:00:00 2001 From: Mike Sutton Date: Wed, 13 Sep 2017 12:54:05 -0700 Subject: [PATCH] Fixed issue 1 by adding a reset for the bool and changing the 'if = ' to 'if ==' :wq :q quit exit --- main.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/main.cpp b/main.cpp index db351ef..bd9d50c 100644 --- a/main.cpp +++ b/main.cpp @@ -1,3 +1,5 @@ +#include + using namespace std; int main() @@ -12,8 +14,9 @@ int main() cin>>num1; cout<<"Enter another whole number: \n"; cin>>num2; + repeat = false; - if( num1 = num2 ) + if( num1 == num2 ) { cout<<"Numbers should be different!\n"; repeat = true;