// Return the set of products that were ordered by every customer fun Shop.getSetOfProductsOrderedByEveryCustomer(): Set { val allProducts = customers.flatMap { it.orders.flatMap { it.products }}.toSet() return customers.fold(allProducts, { orderedByAll, customer -> orderedByAll.intersect(customer.orders.flatMap { it.products }.toSet()) }) }