added country codes, cleaned up output