/**
 * This function takes two strings as input and returns a list of common characters between the two strings.
 *
 * @param string1 The first string.
 * @param string2 The second string.
 * @return A list of common characters between the two strings.
 */
fun findCommonChars(string1: String, string2: String): List<Char> {

    val commonChars = mutableListOf<Char>()

    for (char1 in string1) {
        var flag = true

        for (char2 in string2) {
            if (char1 == char2) {
                commonChars.add(char1)
                flag = false
                break
            }
        }

        if (flag) {
            continue
        }
    }

    return commonChars
}
/**
 * This function takes two strings as input and returns a list of common characters between the two strings.
 *
 * @param string1 The first string.
 * @param string2 The second string.
 * @return A list of common characters between the two strings.
 */
fun findCommonChars(string1: String, string2: String): List<Char> {
/**
 * This function takes two strings as input and returns a list of common characters between the two strings.
 *
 * @param string1 The first string.
 * @param string2 The second string.
 * @return A list of common characters between the two strings.
 */
fun findCommonChars(string1: String, string2: String): List<Char> {

    val commonChars = mutableListOf<Char>()

    for (char1 in string1) {
        var flag = true

        for (char2 in string2) {
            if (char1 == char2) {
                commonChars.add(char1)
                flag = false
                break
            }
        }

        if (flag) {
            continue
        }
    }

    return commonChars
}