fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. int a, b, result;
  6.  
  7. cout << "Enter first number: ";
  8. cin >> a;
  9.  
  10. cout << "Enter second number: ";
  11. cin >> b;
  12.  
  13. result = a - b;
  14.  
  15. cout << "Subtraction of two numbers = " << result;
  16.  
  17. return 0;
  18. }
Success #stdin #stdout 0.01s 5288KB
stdin
20
12
stdout
Enter first number: Enter second number: Subtraction of two numbers = 8