September can still be very warm in Germany. It is technically late summer and both cities will be good to visit. Berlin is further away and while taking the train will let you see more of the Germany it will take about 6 to 6,5 hours. So looking for a cheap flight might be the better way. Another alternative which is dirt cheap but will take 7 hours and won't be this comfortable is to take a long distance bus (like Greyhound).
So at the end it comes to what you want to show your friend. Prague offers more old buildings, the castle and an intact historic old town. Berlin offers a wider variety of night life, a lot of cold war history and of course the famous Döner.