/**
 * Determine if a software developer is a qualified candidate.
 *
 * @param age The age of the developer.
 * @param yearsOfExperience The years of experience of the developer.
 * @return A message indicating whether the developer is a qualified candidate or not.
 */
fun qualifiedCandidate(age: Int, yearsOfExperience: Int): String {

    // Check if the age is between 25 and 40 (inclusive)
    if (age in 25..40) {
        // Check if the developer has at least 5 years of experience
        return when {
            yearsOfExperience >= 5 -> "Qualified candidate"
            yearsOfExperience >= 3 -> "Candidate with potential"
            else -> "Inexperienced candidate"
        }
    }
    // Check if the age is above 40 and has at least 10 years of experience
    return if (age > 40 && yearsOfExperience >= 10) {
        "Senior candidate"
    } else {
        "Not a qualified candidate"
    }
}
/**
 * Determine if a software developer is a qualified candidate.
 *
 * @param age The age of the developer.
 * @param yearsOfExperience The years of experience of the developer.
 * @return A message indicating whether the developer is a qualified candidate or not.
 */
fun qualifiedCandidate(age: Int, yearsOfExperience: Int): String {
/**
 * Determine if a software developer is a qualified candidate.
 *
 * @param age The age of the developer.
 * @param yearsOfExperience The years of experience of the developer.
 * @return A message indicating whether the developer is a qualified candidate or not.
 */
fun qualifiedCandidate(age: Int, yearsOfExperience: Int): String {

    // Check if the age is between 25 and 40 (inclusive)
    if (age in 25..40) {
        // Check if the developer has at least 5 years of experience
        return when {
            yearsOfExperience >= 5 -> "Qualified candidate"
            yearsOfExperience >= 3 -> "Candidate with potential"
            else -> "Inexperienced candidate"
        }
    }
    // Check if the age is above 40 and has at least 10 years of experience
    return if (age > 40 && yearsOfExperience >= 10) {
        "Senior candidate"
    } else {
        "Not a qualified candidate"
    }
}