and hold the shutter button and start counting. at 8 seconds i let it go and check the shot to see if i am getting what i want. i adjust the length of time i hold the shutter open either up or down to get the right exposure.
some cameras will let you do this in camera. if not take two photos - the first in focus and and the second one purposely out of focus then combine them in post processing.
so the next time you find yourself in a city don’t forget to have a look out the hotel window and consider trying to make a few sparkling city night 