Check nb instead of length.