<List find method finds nothing, but let is called...
# stackoverflow
u
List find method finds nothing, but let is called (?!) i have the following code: myList { it.code == item.bin }.let { // 1 } ?: run { // 2 } I would expect that, if item is found, I enter block 1 , otherwise block 2 ; But instead I enter block 1 in all cases, and if nothing is found , it is null Android studio seems aware of this, as the block 2 is grey (it is code never called), but I can't figure why Please may someone explain why ?