fix bug for firstmissingpositive