hasNaN static method

bool hasNaN(
  1. Iterable<num> ns
)

If ns has a NaN value.

Implementation

static bool hasNaN(Iterable<num> ns) {
  if (ns.isEmpty) return false;
  for (var n in ns) {
    if (n.isNaN) return true;
  }
  return false;
}