Is there a way to check if two lists are equal, depending on the values in it but regardless of their order.
for example:
[3,4,5] == [5,3,4] will be: true
You can of course sort the 2 lists and then compare them, the question is whether it is possible to check if lists are equal using their values, without sorting them
>Solution :
You can use Counter from collections
Counter(listA) == Counter(listB)
or if you want to sort them
sorted(listA) == sorted(listB)