/**
 * Determine the salary of an economist based on their income and profession.
 *
 * The salary of an economist is calculated differently based on their profession.
 * If the profession is 'government', the salary is calculated as twice the income.
 * If the profession is 'academic', the salary is calculated as three times the income.
 * For any other profession, the salary is calculated as four times the income.
 *
 * @param income The annual income of the economist.
 * @param profession The profession of the economist.
 * @return The salary of the economist.
 *
 * Example:
 * economistSalary(50000.0, "government") => 100000.0
 * economistSalary(60000.0, "academic") => 180000.0
 * economistSalary(70000.0, "consultant") => 280000.0
 */
fun economistSalary(income: Double, profession: String): Double {

    val salary = income * if (profession == "government") 2.0
    else if (profession == "academic") 3.0
    else 4.0
    return salary
}
/**
 * Determine the salary of an economist based on their income and profession.
 *
 * The salary of an economist is calculated differently based on their profession.
 * If the profession is 'government', the salary is calculated as twice the income.
 * If the profession is 'academic', the salary is calculated as three times the income.
 * For any other profession, the salary is calculated as four times the income.
 *
 * @param income The annual income of the economist.
 * @param profession The profession of the economist.
 * @return The salary of the economist.
 *
 * Example:
 * economistSalary(50000.0, "government") => 100000.0
 * economistSalary(60000.0, "academic") => 180000.0
 * economistSalary(70000.0, "consultant") => 280000.0
 */
fun economistSalary(income: Double, profession: String): Double {
/**
 * Determine the salary of an economist based on their income and profession.
 *
 * The salary of an economist is calculated differently based on their profession.
 * If the profession is 'government', the salary is calculated as twice the income.
 * If the profession is 'academic', the salary is calculated as three times the income.
 * For any other profession, the salary is calculated as four times the income.
 *
 * @param income The annual income of the economist.
 * @param profession The profession of the economist.
 * @return The salary of the economist.
 *
 * Example:
 * economistSalary(50000.0, "government") => 100000.0
 * economistSalary(60000.0, "academic") => 180000.0
 * economistSalary(70000.0, "consultant") => 280000.0
 */
fun economistSalary(income: Double, profession: String): Double {

    val salary = income * if (profession == "government") 2.0
    else if (profession == "academic") 3.0
    else 4.0
    return salary
}