first nonrepeated char
add longest pal