/**
 * This function calculates the total expenses for an accountant given the income and rate of return.
 */
fun calculateTotalExpenses(income: Double, rateOfReturn: Double): Double {

    return try {
        income / rateOfReturn
    } catch (e: ArithmeticException) {
        println("Error: Rate of return cannot be zero.")
        0.0
    } catch (e: Exception) {
        println("An error occurred: ${e.message}")
        0.0
    }
}
/**
 * This function calculates the total expenses for an accountant given the income and rate of return.
 */
fun calculateTotalExpenses(income: Double, rateOfReturn: Double): Double {
/**
 * This function calculates the total expenses for an accountant given the income and rate of return.
 */
fun calculateTotalExpenses(income: Double, rateOfReturn: Double): Double {

    return try {
        income / rateOfReturn
    } catch (e: ArithmeticException) {
        println("Error: Rate of return cannot be zero.")
        0.0
    } catch (e: Exception) {
        println("An error occurred: ${e.message}")
        0.0
    }
}