functionNice(a)print("string: ",a)fori=1,string.len(a)do-- match upper and lower substringifstring.find(a,string.upper(string.sub(a,i,i)))~=nilandstring.find(a,string.lower(string.sub(a,i,i)))~=nilthenio.write(string.sub(a,i,i))endendprint("")endNice("YaaAho")Nice("cC")Nice("A")