last function

dynamic last(
  1. List list
)

Gets the last element of list. Uses dart's List.last property Example

_.last(["Dart", "Javascript", "Swift"]);
// Returns "Swift"

Implementation

dynamic last(List list) {
  return list.last;
}