/**
 * You are tasked with creating a dictionary containing the statistics of each firefighter in a fire department.
 * The firefighters' names are provided as keys, and their corresponding stats are provided as values.
 * Your task is to complete the code to populate the dictionary according to the given inputs.
 *
 * @param firefighters a list of firefighter names (strings)
 * @param stats a list of their corresponding statistics (strings)
 * @return A dictionary containing the firefighters' stats, with names as keys and stats as values.
 * If the lengths of the input lists differ, the dictionary should only contain stats for the first 'n' firefighters,
 * where 'n' is the length of the shorter list.
 */
fun createFirefighterStats(firefighters: List<String>, stats: List<String>): Map<String, String> {

    val firefighterStats = mutableMapOf<String, String>()

    // Loop through the firefighters list and assign their stats to the dictionary
    for (i in firefighters.indices) {
        if (i >= stats.size) {
            break
        }
        firefighterStats[firefighters[i]] = stats[i]
    }

    return firefighterStats
}
/**
 * You are tasked with creating a dictionary containing the statistics of each firefighter in a fire department.
 * The firefighters' names are provided as keys, and their corresponding stats are provided as values.
 * Your task is to complete the code to populate the dictionary according to the given inputs.
 *
 * @param firefighters a list of firefighter names (strings)
 * @param stats a list of their corresponding statistics (strings)
 * @return A dictionary containing the firefighters' stats, with names as keys and stats as values.
 * If the lengths of the input lists differ, the dictionary should only contain stats for the first 'n' firefighters,
 * where 'n' is the length of the shorter list.
 */
fun createFirefighterStats(firefighters: List<String>, stats: List<String>): Map<String, String> {
/**
 * You are tasked with creating a dictionary containing the statistics of each firefighter in a fire department.
 * The firefighters' names are provided as keys, and their corresponding stats are provided as values.
 * Your task is to complete the code to populate the dictionary according to the given inputs.
 *
 * @param firefighters a list of firefighter names (strings)
 * @param stats a list of their corresponding statistics (strings)
 * @return A dictionary containing the firefighters' stats, with names as keys and stats as values.
 * If the lengths of the input lists differ, the dictionary should only contain stats for the first 'n' firefighters,
 * where 'n' is the length of the shorter list.
 */
fun createFirefighterStats(firefighters: List<String>, stats: List<String>): Map<String, String> {

    val firefighterStats = mutableMapOf<String, String>()

    // Loop through the firefighters list and assign their stats to the dictionary
    for (i in firefighters.indices) {
        if (i >= stats.size) {
            break
        }
        firefighterStats[firefighters[i]] = stats[i]
    }

    return firefighterStats
}