/**
 * This function takes in a list of police officers' names and a target name to search for.
 * It returns true if the target name is present in the database, otherwise it returns false.
 * Complete the code by using a for loop to iterate through the names and performing a selection check.
 */
fun searchOfficer(database: List<String>, targetName: String): Boolean {

    for (name in database) {
        if (name == targetName) { // Complete the selection check
            return true // Return true if the target name is found
        }
    }
    return false // Return false if the target name is not found
}

// Example usage
/**
 * This function takes in a list of police officers' names and a target name to search for.
 * It returns true if the target name is present in the database, otherwise it returns false.
 * Complete the code by using a for loop to iterate through the names and performing a selection check.
 */
fun searchOfficer(database: List<String>, targetName: String): Boolean {
/**
 * This function takes in a list of police officers' names and a target name to search for.
 * It returns true if the target name is present in the database, otherwise it returns false.
 * Complete the code by using a for loop to iterate through the names and performing a selection check.
 */
fun searchOfficer(database: List<String>, targetName: String): Boolean {

    for (name in database) {
        if (name == targetName) { // Complete the selection check
            return true // Return true if the target name is found
        }
    }
    return false // Return false if the target name is not found
}

// Example usage