0

the code is:-

import pymongo
cur=pymongo.MongoClient()

db=cur.test1
for site in db.sites.find():
    print(site)

In the output, why the sequence is different everytime? It should be url first and then name as filled. ouput screenshot

Rohit Poudel
  • 1,793
  • 2
  • 20
  • 24
user8482601
  • 67
  • 1
  • 9

1 Answers1

0

There is no order in dictionaries , these are just key,value pairs so it is normal to have a different output everytime.

EY.Mohamed
  • 82
  • 6