/**
 * Takes two sets of tools used by firefighters and returns a set containing the tools that are common to both sets.
 *
 * @param tools1 Set of tools used by the first firefighter
 * @param tools2 Set of tools used by the second firefighter
 * @return Set of tools that are common to both firefighters
 *
 * Examples:
 * tools1 = setOf("axe", "hose", "crowbar", "chainsaw")
 * tools2 = setOf("extraction tool", "fire extinguisher", "crowbar", "chainsaw")
 * findCommonTools(tools1, tools2) // Output: setOf("crowbar", "chainsaw")
 */
fun findCommonTools(tools1: Set<String>, tools2: Set<String>): Set<String> {

    // Using set intersection to find common tools
    return tools1.intersect(tools2)
}
/**
 * Takes two sets of tools used by firefighters and returns a set containing the tools that are common to both sets.
 *
 * @param tools1 Set of tools used by the first firefighter
 * @param tools2 Set of tools used by the second firefighter
 * @return Set of tools that are common to both firefighters
 *
 * Examples:
 * tools1 = setOf("axe", "hose", "crowbar", "chainsaw")
 * tools2 = setOf("extraction tool", "fire extinguisher", "crowbar", "chainsaw")
 * findCommonTools(tools1, tools2) // Output: setOf("crowbar", "chainsaw")
 */
fun findCommonTools(tools1: Set<String>, tools2: Set<String>): Set<String> {
/**
 * Takes two sets of tools used by firefighters and returns a set containing the tools that are common to both sets.
 *
 * @param tools1 Set of tools used by the first firefighter
 * @param tools2 Set of tools used by the second firefighter
 * @return Set of tools that are common to both firefighters
 *
 * Examples:
 * tools1 = setOf("axe", "hose", "crowbar", "chainsaw")
 * tools2 = setOf("extraction tool", "fire extinguisher", "crowbar", "chainsaw")
 * findCommonTools(tools1, tools2) // Output: setOf("crowbar", "chainsaw")
 */
fun findCommonTools(tools1: Set<String>, tools2: Set<String>): Set<String> {

    // Using set intersection to find common tools
    return tools1.intersect(tools2)
}