/**
 * This function takes in two lists and returns the intersection of the two lists using list comprehension.
 *
 * @param list1 First input list
 * @param list2 Second input list
 * @return Intersection of the two lists
 *
 * Example:
 * intersectionOfNoneAndListComprehension(listOf(1, 2, 3, 4, 5), listOf(4, 5, 6, 7, 8)) // [4, 5]
 * intersectionOfNoneAndListComprehension(listOf("apple", "banana", "orange"), listOf("pear", "banana", "grape")) // ["banana"]
 */
fun intersectionOfNoneAndListComprehension(list1: List<Any>, list2: List<Any>): List<Any> {

    return list1.filter { it in list2 }
}
/**
 * This function takes in two lists and returns the intersection of the two lists using list comprehension.
 *
 * @param list1 First input list
 * @param list2 Second input list
 * @return Intersection of the two lists
 *
 * Example:
 * intersectionOfNoneAndListComprehension(listOf(1, 2, 3, 4, 5), listOf(4, 5, 6, 7, 8)) // [4, 5]
 * intersectionOfNoneAndListComprehension(listOf("apple", "banana", "orange"), listOf("pear", "banana", "grape")) // ["banana"]
 */
fun intersectionOfNoneAndListComprehension(list1: List<Any>, list2: List<Any>): List<Any> {
/**
 * This function takes in two lists and returns the intersection of the two lists using list comprehension.
 *
 * @param list1 First input list
 * @param list2 Second input list
 * @return Intersection of the two lists
 *
 * Example:
 * intersectionOfNoneAndListComprehension(listOf(1, 2, 3, 4, 5), listOf(4, 5, 6, 7, 8)) // [4, 5]
 * intersectionOfNoneAndListComprehension(listOf("apple", "banana", "orange"), listOf("pear", "banana", "grape")) // ["banana"]
 */
fun intersectionOfNoneAndListComprehension(list1: List<Any>, list2: List<Any>): List<Any> {

    return list1.filter { it in list2 }
}