/**
 * Given a dictionary of patient data, calculate the mean heart rate of the patients.
 *
 * @param patientData A dictionary of patient data with 'Name' as key and 'HeartRate' as value
 * @return The mean heart rate as a float
 */
fun calculateMeanHeartRate(patientData: Map<String, Any>): Float {

    if (patientData.isNotEmpty()) {
        var sumHeartRate = 0f
        var numPatients = 0
        for ((_, heartRate) in patientData) {
            if (heartRate is Float || heartRate is Int) {
                sumHeartRate += heartRate as Float
                numPatients++
            }
        }
        return sumHeartRate / numPatients
    }
    return 0f
}
/**
 * Given a dictionary of patient data, calculate the mean heart rate of the patients.
 *
 * @param patientData A dictionary of patient data with 'Name' as key and 'HeartRate' as value
 * @return The mean heart rate as a float
 */
fun calculateMeanHeartRate(patientData: Map<String, Any>): Float {
/**
 * Given a dictionary of patient data, calculate the mean heart rate of the patients.
 *
 * @param patientData A dictionary of patient data with 'Name' as key and 'HeartRate' as value
 * @return The mean heart rate as a float
 */
fun calculateMeanHeartRate(patientData: Map<String, Any>): Float {

    if (patientData.isNotEmpty()) {
        var sumHeartRate = 0f
        var numPatients = 0
        for ((_, heartRate) in patientData) {
            if (heartRate is Float || heartRate is Int) {
                sumHeartRate += heartRate as Float
                numPatients++
            }
        }
        return sumHeartRate / numPatients
    }
    return 0f
}