/**
 * This function takes two lists of animals and returns the number of common animals.
 *
 * @param animalList1 First list of animals.
 * @param animalList2 Second list of animals.
 * @return The number of common animals between the two lists.
 */
fun countCommonAnimals(animalList1: List<String>, animalList2: List<String>): Int {

    val commonAnimals = mutableListOf<String>()

    for (animal1 in animalList1) {
        for (animal2 in animalList2) {
            if (animal1 == animal2) {
                commonAnimals.add(animal1)
            }
        }
    }

    return commonAnimals.size
}
/**
 * This function takes two lists of animals and returns the number of common animals.
 *
 * @param animalList1 First list of animals.
 * @param animalList2 Second list of animals.
 * @return The number of common animals between the two lists.
 */
fun countCommonAnimals(animalList1: List<String>, animalList2: List<String>): Int {
/**
 * This function takes two lists of animals and returns the number of common animals.
 *
 * @param animalList1 First list of animals.
 * @param animalList2 Second list of animals.
 * @return The number of common animals between the two lists.
 */
fun countCommonAnimals(animalList1: List<String>, animalList2: List<String>): Int {

    val commonAnimals = mutableListOf<String>()

    for (animal1 in animalList1) {
        for (animal2 in animalList2) {
            if (animal1 == animal2) {
                commonAnimals.add(animal1)
            }
        }
    }

    return commonAnimals.size
}