lastWhereOrNull method
Implementation
E? lastWhereOrNull(bool test(E element)) {
if (this == null || this!.isEmpty) return null;
E? result;
bool foundMatching = false;
for (E element in this!) {
if (test(element)) {
result = element;
foundMatching = true;
}
}
if (foundMatching) return result;
return null;
}