/**
 * Given two tuples t1 and t2, the function should return a new tuple that contains all the elements from t1
 * but with repeated elements from t2 removed.
 *
 * Example:
 * t1 = (1, 2, 3, 4, 5)
 * t2 = (3, 4, 5)
 * output = (1, 2)
 *
 * @param t1 First tuple
 * @param t2 Second tuple
 * @return New tuple with repeated elements removed from t1
 */
fun loopTupleControl(t1: List<Int>, t2: List<Int>): List<Int> {

    val t1Modified = mutableListOf<Int>()
    for (element in t1) {  // Loop through each element in t1
        var repeated = false
        for (item in t2) {  // Loop through each element in t2
            if (element == item) {  // Check if element is repeated in t2
                repeated = true
                break  // If repeated, break out of the second loop
            }
        }
        if (!repeated) {  // If element is not repeated, add it to the modified list
            t1Modified.add(element)
        }
    }
    return t1Modified
}
/**
 * Given two tuples t1 and t2, the function should return a new tuple that contains all the elements from t1
 * but with repeated elements from t2 removed.
 *
 * Example:
 * t1 = (1, 2, 3, 4, 5)
 * t2 = (3, 4, 5)
 * output = (1, 2)
 *
 * @param t1 First tuple
 * @param t2 Second tuple
 * @return New tuple with repeated elements removed from t1
 */
fun loopTupleControl(t1: List<Int>, t2: List<Int>): List<Int> {
/**
 * Given two tuples t1 and t2, the function should return a new tuple that contains all the elements from t1
 * but with repeated elements from t2 removed.
 *
 * Example:
 * t1 = (1, 2, 3, 4, 5)
 * t2 = (3, 4, 5)
 * output = (1, 2)
 *
 * @param t1 First tuple
 * @param t2 Second tuple
 * @return New tuple with repeated elements removed from t1
 */
fun loopTupleControl(t1: List<Int>, t2: List<Int>): List<Int> {

    val t1Modified = mutableListOf<Int>()
    for (element in t1) {  // Loop through each element in t1
        var repeated = false
        for (item in t2) {  // Loop through each element in t2
            if (element == item) {  // Check if element is repeated in t2
                repeated = true
                break  // If repeated, break out of the second loop
            }
        }
        if (!repeated) {  // If element is not repeated, add it to the modified list
            t1Modified.add(element)
        }
    }
    return t1Modified
}