initial commit of isValid Chromosome function