length checks in pretty printing for table