possibilities in string =========================== str1=" PO BOx 1234, Hyde" str2=" PO BOx 1234, Hyd" str3=" PO BOx 1234, Hbad" str4=" PO BOx 1234, Hbd" possiblities in list=[Hyde,Hyd Hyderab,Hyderabad,Hbad,Hbd] we need to extract city from the string and check the city in list. if matches it shoild convert into hyderabad Ex: extracted city part is "Hbd" if that varible matches in List [Hyde,Hyd Hyderab,Hyderabad,Hbad,Hbd] it should convertsinto Hyderabad new string is str=" PO BOx 1234, Hyderabad"