Untitled
unknown
plain_text
2 years ago
725 B
16
Indexable
#include <bits/stdc++.h>
using namespace std;
int main() {
double monthlySalary;
// Prompt the user for the monthly salary
cout << "Enter the monthly salary: ";
cin >> monthlySalary;
double annualSalary = monthlySalary * 12; // Calculate annual salary
// Determine the employee level based on annual salary
string employeeLevel;
if (annualSalary >= 20000) {
employeeLevel = "Executive";
} else if (annualSalary >= 12000) {
employeeLevel = "Administrative";
} else {
employeeLevel = "Base";
}
// Output the classification
cout << "Employee level: " << employeeLevel << endl;
return 0;
}
Editor is loading...