The location is most important to take a good picture! Usually when I get to travel somewhere I use different kind of sources to find the sweet spots where I travel at:
#1: Internet search
I pretty often use online sites like Google Maps, Google, 500px or flickr. Those sites are giving ideas where to take the best pictures at your current positon. Usually I do not have free data where I travel to so I have to do that research before I get on a trip.
#2: Ask the locals
The locals usually know where to take pictures at. I often ask in the hotel lobby and the people there are really friendly – often it happens that they ask friends or start using the internet for you.
#3: Find the next bookstore
In case you have trouble with the local language there are many guide books available in your own language. Buy the book prior to your trip and you have some reading material on the way there.
#4: Just randomly walk around
This is what I pretty often do: I just walk around and whenever I find something interesting I put my camera in position and start shooting. Please check before what locations are safe! There might be some of the locations that you do not want to be at during a particular time…