How to get a list of available unique values in a Mongo DB?

All good! Started to learn Mongu. Google found no answer, as I suspect is not quite correct I have the request turned out. That's what I mean.
Have a collection myCollection :

{"_id":"01", "city": "London", "number": "11", "isActive": "true"}
{"_id":"02", "city": "Paris", "number": "31", "isActive": "true"}
{"_id":"03", "city": "Moscow", "number": "1", "isActive": "false"}
{"_id":"04", "city": "Kiev", "number": "131", "isActive": "true"}
{"_id":"05", "city": "London", "number": "551", "isActive": "true"}
{"_id":"07", "city": "London", "number": "11", "isActive": "true"}
{"_id":"08", "city": "London", "number": "44", "isActive": "true"}
{"_id":"09", "city": "Paris", "number": "77", "isActive": "false"}
{"_id":"10", "city": "Kiev", "number": "77", "isActive": "true"}
{"_id":"11", "city": "Paris", "number": "22", "isActive": "false"}
{"_id":"12", "city": "Paris", "number": "8", "isActive": "true"}


How can I get only city names without duplicates?

{"city": "London" }
{"city": "Paris"}
{"city": "Moscow"}
{"city": "Kiev"}


I mean, to see only what cities are

Or just an array with the cities without duplicates:

["London", "Paris", "Moscow", "Kiev"]
June 3rd 19 at 19:34
2 answers
June 3rd 19 at 19:36
June 3rd 19 at 19:38
Sorry, kind of as found :)

db.myCollection.distinct("city")

Find more questions by tags DatabasesNoSQLMongoDB