/**
 * This function takes two strings as input and prints the common characters found in both strings.
 * The function uses loops and boolean expressions to find the common characters.
 */
fun printCommonCharacters(string1: String, string2: String) {

    // Iterate over each character in string1
    for (char1 in string1) {
        // Initialize a boolean flag to check if character is common
        var isCommon = false
        
        // Iterate over each character in string2
        for (char2 in string2) {
            // Check if the characters match
            if (char1 == char2) {
                // Set the boolean flag to true indicating character is common
                isCommon = true
                break
            }
        }
        
        // Print the common character if found
        if (isCommon) {
            println(char1)
        }
    }
}
/**
 * This function takes two strings as input and prints the common characters found in both strings.
 * The function uses loops and boolean expressions to find the common characters.
 */
fun printCommonCharacters(string1: String, string2: String) {
/**
 * This function takes two strings as input and prints the common characters found in both strings.
 * The function uses loops and boolean expressions to find the common characters.
 */
fun printCommonCharacters(string1: String, string2: String) {

    // Iterate over each character in string1
    for (char1 in string1) {
        // Initialize a boolean flag to check if character is common
        var isCommon = false
        
        // Iterate over each character in string2
        for (char2 in string2) {
            // Check if the characters match
            if (char1 == char2) {
                // Set the boolean flag to true indicating character is common
                isCommon = true
                break
            }
        }
        
        // Print the common character if found
        if (isCommon) {
            println(char1)
        }
    }
}