fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. int x;
  6. char y;
  7.  
  8. cout << "Enter the number: " << endl;
  9. cin >> x;
  10. cout << "Your number is: " << x << endl;
  11.  
  12. cout << "Enter the char: " << endl;
  13. cin >> y;
  14. cout << "Your char is: " << y << endl;
  15. }
Success #stdin #stdout 0.01s 5264KB
stdin
40
A
stdout
Enter the number: 
Your number is: 40
Enter the char: 
Your char is: A