Add min/max management.
Fix: empty line at the end considered as a full row.