I have a data frame named A which are company names and cities, like
A:
name city IBM NY AMZ NY ALI SH TAOBAO London