What is the best way to remove distances in the following lines and output cdv format. Can this be done reasonably easily on the command line? I'd like to avoid having to write a full-blow script.
Greece 282 km, Macedonia 151 km, Montenegro 172 km, Kosovo 112 km Central African Republic 797 km, Chad 1,094 km, Republic of the Congo 523
The output would be:
Greece,Macedonia,Montenegro,Kosovo Central African Republic,Chad,Republic of the Congo