What were the cities of Berlin and Hamberg formed from