fork download
  1. #include<iostream>
  2. using namespace std;
  3.  
  4. int main(){
  5. int number1;
  6. int number2;
  7. cout << "Enter two integers to compare: ";
  8. cin >> number1 >> number2;
  9.  
  10. if (number1 == number2)
  11. cout << number1 << " == " << number2 << endl;
  12.  
  13. if (number1 > number2)
  14. cout << number1 << " > " << number2 << endl;
  15.  
  16. return 0;
  17.  
  18. }
Success #stdin #stdout 0s 15240KB
stdin
22 8
stdout
Enter two integers to compare: 22 > 8