Kotlin: Comparing two different lists with different sizes to find a shared value and change elements when it occurs
Given list A containing the following data:
arrayListOf(Product(uid = "1", name = "Product 1", isOnListB = false), Product(uid = "2", name = "Product 2", isOnListB = false), Product(uid = "3", name = "Product 3", isOnListB = false))
And list B containing the following:
arrayListOf(FavoriteProduct(uid = "2", dateAdded = "Today"))
What is Kotlin's idiomatic way to see if a product on list A is on list B and then make a change to that product?
In the example above, you can see that both lists...