/**
 * Given a list of photos, the function filters the photos based on the following criteria:
 * - If the photo has a resolution higher than 10 megapixels and the photographer has more than 
 *   5 years of experience, the photo is accepted.
 * - If the photo has a resolution higher than 8 megapixels and the photographer has more than 
 *   3 years of experience, the photo is accepted.
 * - If the photo has a resolution higher than 5 megapixels and the photographer has more than 
 *   1 year of experience, the photo is accepted.
 * - Otherwise, the photo is rejected.
 *
 * @param photos A list of dictionaries containing the photo information.
 * @return A list of photos that fulfill the acceptance criteria.
 */
fun filterPhotos(photos: List<Map<String, Any>>): List<Map<String, Any>> {

    val acceptedPhotos = photos.filter { photo ->
        (photo["resolution"] as Int > 10 && photo["experience"] as Int > 5) ||
        (photo["resolution"] as Int > 8 && photo["experience"] as Int > 3) ||
        (photo["resolution"] as Int > 5 && photo["experience"] as Int > 1)
    }
    return acceptedPhotos
}
/**
 * Given a list of photos, the function filters the photos based on the following criteria:
 * - If the photo has a resolution higher than 10 megapixels and the photographer has more than 
 *   5 years of experience, the photo is accepted.
 * - If the photo has a resolution higher than 8 megapixels and the photographer has more than 
 *   3 years of experience, the photo is accepted.
 * - If the photo has a resolution higher than 5 megapixels and the photographer has more than 
 *   1 year of experience, the photo is accepted.
 * - Otherwise, the photo is rejected.
 *
 * @param photos A list of dictionaries containing the photo information.
 * @return A list of photos that fulfill the acceptance criteria.
 */
fun filterPhotos(photos: List<Map<String, Any>>): List<Map<String, Any>> {
/**
 * Given a list of photos, the function filters the photos based on the following criteria:
 * - If the photo has a resolution higher than 10 megapixels and the photographer has more than 
 *   5 years of experience, the photo is accepted.
 * - If the photo has a resolution higher than 8 megapixels and the photographer has more than 
 *   3 years of experience, the photo is accepted.
 * - If the photo has a resolution higher than 5 megapixels and the photographer has more than 
 *   1 year of experience, the photo is accepted.
 * - Otherwise, the photo is rejected.
 *
 * @param photos A list of dictionaries containing the photo information.
 * @return A list of photos that fulfill the acceptance criteria.
 */
fun filterPhotos(photos: List<Map<String, Any>>): List<Map<String, Any>> {

    val acceptedPhotos = photos.filter { photo ->
        (photo["resolution"] as Int > 10 && photo["experience"] as Int > 5) ||
        (photo["resolution"] as Int > 8 && photo["experience"] as Int > 3) ||
        (photo["resolution"] as Int > 5 && photo["experience"] as Int > 1)
    }
    return acceptedPhotos
}