Another FILTERXML hack. Suppose you have following string of words in cell A2
Moscow, London, Paris, Delhi, Washington, Miami, Detroit, Berlin
You want to reverse this string of words and want following output.
Berlin, Detroit, Miami, Washington, Delhi, Paris, London, Moscow
FILTERXML will come to your rescue. You can use following formula for this
=TEXTJOIN(", ",,INDEX(FILTERXML("<t><s>"&SUBSTITUTE(A2,", ","</s><s>")&"</s></t>","//s"),LEN(A2)-LEN(SUBSTITUTE(A2,", "," "))+2-ROW(INDIRECT("1:"&LEN(A2)-LEN(SUBSTITUTE(A2,", "," "))+1))))
If you are on latest version of Office 365 thus have Dynamic array functionality, then above formula can be made shorter
=TEXTJOIN(", ",,SORTBY(FILTERXML("<t><s>"&SUBSTITUTE(A2,", ","</s><s>")&"</s></t>","//s"),SEQUENCE(LEN(A2)-LEN(SUBSTITUTE(A2,", ", " "))+1),-1))