Last active
April 5, 2017 15:09
-
-
Save saginadir/7d7e720b750acd350d24b24a966de6fd to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
using namespace std; | |
int main() | |
{ | |
int num, c, d, e; | |
do { | |
cout << "Enter a 2 digit numbers:"<< endl; | |
cin >> num; | |
int a = num / 10; | |
int b = num % 10; | |
if (num >= 10 && num <= 100) { | |
c = a + b; | |
d = a - b; | |
e = a * b; | |
cout << "chibur:" << c << endl; | |
cout << "chisur:" << d << endl; | |
cout << "kefel:" << e << endl; | |
break; | |
} | |
cout << "Input must be in double digits!" << endl; | |
} while (num < 10 || num > 100); | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment