judge method

T? judge(
  1. List<bool> line
)

Implementation

T? judge(List<bool> line) {
  for (int i = 0; i < line.length; ++i) {
    if (line[i]) {
      return this[i];
    }
  }
  if (length > line.length) {
    return this.last;
  }
  return null;
}