/**
 * The function checks the soil condition based on the soil moisture and pH values.
 *
 * @param soilMoisture The soil moisture level.
 * @param soilPh The soil pH level.
 * @return The condition of the soil based on the given moisture and pH values.
 */
fun checkSoilCondition(soilMoisture: Double, soilPh: Double): String {

    return when {
        soilMoisture < 0.2 -> when {
            soilPh < 4.5 -> "Acidic and extremely dry"
            soilPh < 6.5 -> "Slightly acidic and extremely dry"
            soilPh < 7.5 -> "Neutral and extremely dry"
            else -> "Alkaline and extremely dry"
        }
        soilMoisture < 0.4 -> when {
            soilPh < 4.5 -> "Acidic and very dry"
            soilPh < 6.5 -> "Slightly acidic and very dry"
            soilPh < 7.5 -> "Neutral and very dry"
            else -> "Alkaline and very dry"
        }
        else -> {
            // Handle other cases for soil moisture levels
            "Other soil condition"
        }
    }
}
/**
 * The function checks the soil condition based on the soil moisture and pH values.
 *
 * @param soilMoisture The soil moisture level.
 * @param soilPh The soil pH level.
 * @return The condition of the soil based on the given moisture and pH values.
 */
fun checkSoilCondition(soilMoisture: Double, soilPh: Double): String {
/**
 * The function checks the soil condition based on the soil moisture and pH values.
 *
 * @param soilMoisture The soil moisture level.
 * @param soilPh The soil pH level.
 * @return The condition of the soil based on the given moisture and pH values.
 */
fun checkSoilCondition(soilMoisture: Double, soilPh: Double): String {

    return when {
        soilMoisture < 0.2 -> when {
            soilPh < 4.5 -> "Acidic and extremely dry"
            soilPh < 6.5 -> "Slightly acidic and extremely dry"
            soilPh < 7.5 -> "Neutral and extremely dry"
            else -> "Alkaline and extremely dry"
        }
        soilMoisture < 0.4 -> when {
            soilPh < 4.5 -> "Acidic and very dry"
            soilPh < 6.5 -> "Slightly acidic and very dry"
            soilPh < 7.5 -> "Neutral and very dry"
            else -> "Alkaline and very dry"
        }
        else -> {
            // Handle other cases for soil moisture levels
            "Other soil condition"
        }
    }
}