Answered step by step
Verified Expert Solution
Question
1 Approved Answer
You have been provided a code for creating a deck of cards: deck _ of _ cards.py . In addition you have been given a
You have been provided a code for creating a deck of cards: deckofcards.py In addition you have been given a few different codes for sorting elements in a list: quicksort.py bubblesort.py insertsort.py and selectionsort.py What you have been
tasked to do is:
Utilize one of the above sorting algorithms to sort the cards in the deck
Both by suit and by value.
The suits should be ordered in the same order in which the deck is created see line of deckofcards.py
Create a property that determines whether or not the deck is sorted.
Create a search method that allows a user to describe a card and will return the location array index of the card.
This search can easily be made to be high intelligent
What can you do to make this search a constant time look up
Finish all other leftover TODO's in the code as described
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started