def merge_price_dicts(base_prices, price_adjustments):
result = {}
for city, base_prices_dict in base_prices.items():
if city not in result:
result[city] = {}
for product, base_price in base_prices_dict.items():
if city in price_adjustments and product in price_adjustments[city]:
result[city][product] = base_price + price_adjustments[city][product]
else:
result[city][product] = base_price
for city, adjustment_dict in price_adjustments.items():
if city not in result:
result[city] = {}
for product, adjustment in adjustment_dict.items():
if product not in result[city]:
result[city][product] = adjustment
return result