GH avatar Bite 80. Check equality of two lists

In this Bite we compare two list objects for equality, a fundamental thing to understand in Python.

Complete the check_equality function returning the various Enum values (representing equality scores) according to the type of equality of the lists:

  1. return SAME_REFERENCE if both lists reference the same object,
  2. return SAME_ORDERED if they have the same content and order,
  3. return SAME_UNORDERED if they have the same content unordered,
  4. return SAME_UNORDERED_DEDUPED if they have the same unordered content and reduced to unique items,
  5. and finally return NO_EQUALITY if none of the previous cases match.

Have fun and keep calm and code in Python!

go back Beginner level
Bitecoin 2X

152 out of 156 users completed this Bite.
Will you be Pythonista #153 to crack this Bite?
Resolution time: ~46 min. (avg. submissions of 5-240 min.)
Pythonistas rate this Bite 3.0 on a 1-10 difficulty scale.
» You can do it! 😌

Buy Now Login and get coding
We use Python 3.7