Advertisement
NovaKun

calc c++

Mar 9th, 2020
139
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.87 KB | None | 0 0
  1. // Example program
  2. #include <iostream>
  3. #include <string>
  4.  
  5. int main()
  6. {
  7. int digit1;
  8. int digit2;
  9. int process;
  10. //information gathering process
  11. std::cout << "calculator proj.\n";
  12. std::cout << "Please enter your first number: ";
  13. std::cin >> digit1; //grabbing digit1 from user
  14. std::cout << "\n";
  15. std::cout << "Please enter your second number: ";
  16. std::cin >> digit2; //grabbing second digit
  17. std::cout << "\n";
  18. //menu 1
  19. std::cout << "--------------------------------";
  20. std::cout << "1 - Multiply\n";
  21. std::cout << "2 - Divide\n";
  22. std::cout << "3 - Add\n";
  23. std::cout << "4 - Subtract\n";
  24. std::cout << "--------------------------------";
  25. std::cout << "\n";
  26. std::cout << "Please select a process using a single digit: ";
  27. std::cin >> process;
  28. std::cout << "\n";
  29. if (proc)
  30. //calculation
  31.  
  32.  
  33. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement