We have to implement a similarity function f between 2 PlayableDeck.
Something like get_decks_similarity(deck1, deck2) that returns a real value in [0, 1].
The function f should return 0 for two decks that have nothing in common, and 1 for two decks completely identical.
We should find a clever way to weight the (dis)similarity in the decklist.
For example, playing two different cards should be considered "more different" than playing two different quantities of the same card.
We have to implement a similarity function
f
between 2PlayableDeck
. Something likeget_decks_similarity(deck1, deck2)
that returns a real value in [0, 1].The function
f
should return 0 for two decks that have nothing in common, and 1 for two decks completely identical. We should find a clever way to weight the (dis)similarity in the decklist. For example, playing two different cards should be considered "more different" than playing two different quantities of the same card.Bonus: write test cases.