flatten method

List flatten(
  1. List list
)

Implementation

List flatten(List list) {
  for (int j = getDim(list).length; j > 1; j--) {
    list = list.expand((i) => i).toList();
  }
  return list;
}