From 8898521ebb9b8daea209160a7b66c1a2006a1c93 Mon Sep 17 00:00:00 2001 From: Chris Huntington Date: Wed, 13 Sep 2017 20:26:16 -0700 Subject: [PATCH] fixed issues #1 and #2 --- main.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/main.cpp b/main.cpp index cf29c37..64620f7 100644 --- a/main.cpp +++ b/main.cpp @@ -1,4 +1,5 @@ using namespace std; +#include int main() { @@ -12,12 +13,14 @@ int main() cin>>num1; cout<<"Enter another whole number: "; cin>>num2; - - if( num1 = num2 ) + if( num1 == num2 ) { cout<<"Numbers should be different!"; repeat = true; } + else { + repeat = false; + } }while(repeat); cout<<"Increasing order: "; @@ -32,4 +35,3 @@ int main() return 0; } -