popitem () method in Python 3.10 does not work as it worked in Python 3.7

322 views Asked by At

In Python 3.7 popitem () method return and remove random pair key-values. But in Python 3.10 popitem () return and remove LIFO pair key-values. What can i use instead popitem () in Python 3.10 for return and remove random pair in dictionary? Thanks!

0

There are 0 answers