The calculated distance (air line) between Ulcinj and Kotor is approximately 41 miles respectively 66 kilometers.
By car or train, the actual journey to Kotor is certainly longer, as only the direct route (as the crow flies) between Ulcinj and Kotor has been calculated here.