MasterGun

Untitled

May 16th, 2020
35
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include <iostream>
  2. #include <string>
  3. using namespace std;
  4. class student
  5. {
  6. double bal;
  7. double stag;
  8. public:
  9. student(double bal, double stag)
  10. {
  11. this->bal = bal;
  12. this->stag = stag;
  13. }
  14. void cal() {
  15. int bonus;
  16. if (bal == 1)
  17. {
  18. bonus = 1;
  19. }
  20. else if (bal == 2 && 5)
  21. {
  22. bonus = 16;
  23. }
  24. else {
  25. cout << "WELL, he programer made a mistake or your stage is too low, try again" << endl;
  26. }
  27. double calresult = bonus * stag;
  28. cout << bonus*stag << endl;
  29. if (calresult >= 45) {
  30. cout << "You are in " << endl;
  31. }
  32. else {
  33. cout << "Your are not ap to job" << endl;
  34. }
  35. }
  36.  
  37. };
  38. int main(){
  39. setlocale(LC_ALL, "Russian");
  40. double balu;
  41. cout << "Enter your score" << endl;
  42. cin >> balu;
  43. double stage;
  44. cout << "Enter your work exp" << endl;
  45. cin >> stage;
  46. student s(balu,stage);
  47. s.cal();
  48. return 0;
RAW Paste Data