Module 1 course project: arraylist real-world speed

IMPORTANT: Be sure your methods are all at the same indentation level (proper indentation – see screenshot below)

Graphical user interface, text, application  Description automatically generated

6. Copy the ArrayList.py file to this folder. We will use the ArrayList code to check the speed of this algorithm.

7. In this same folder, create a file called ArrayListActualSpeed.py. Type your name and the current date at the top of the code. Then, import the ArrayList class, the Client class, the Quicksort class, the date module from the datetime library, the time module, the random module, and the sys module.

8. In the same ArrayListActualSpeed.py file, display your name and the current date in the output to show that you are the author of this code.

9. In the same ArrayListActualSpeed.py file, create a list and read the records from the ClientData.csv file into Client objects and place the Client objects into the list.

10. In the same Python code file, create an ArrayList object. Let’s test the first scenario. If you accept jobs at the back of the line and then process the jobs from the front of the line, which data structure is best? Write code to test how much time that it takes to add the Client objects from the list into the ArrayList data structure. The ArrayList automatically adds the new records to the end of the data structure so add this time to the spreadsheet into the “Add many records to end of data structure” row in the Excel table.

11. Continue the ArrayListActualSpeed code and write code to test how much time it takes to remove all of the Client objects from the front of the ArrayList, one object at a time. Add this time to the spreadsheet into the “Pull all records off front of data structure” row in the Excel table.

12. Now, let’s test the second scenario. A customer service center receives calls from random customers. The customer service center must be able to quickly pull up the customer’s record. Is the ArrayList good for this scenario? Let’s see how long it takes to pull up random records. Write code to add all of the customers to the ArrayList again since we deleted all of the customers on the last step. Now, write code to test how much time it takes to display many random records. Add this time to the spreadsheet into the “Display random records” row in the Excel table.

13. Let’s consider the third scenario. Consider a credit card call center. The representatives may sign up new credit card accounts (add records). The representatives may answer customers’ questions (display random records). Finally, the representatives may delete a paid-off account at the request of the customer (remove records). Write code to test how much time it takes to add the Client records to the ArrayList, then randomly display records, and then randomly delete records. Add this time to the spreadsheet into the bottom row.

14. If the data is sorted, will the ArrayList run faster? If you have sorted data, you can use the search_sorted( ) method. We will talk about different searching methods in a couple of weeks! Let’s check the difference in speed for the ArrayList when you use sorted and unsorted data.

15. In your ArrayListActualSpeed.py code, add this line after you read the client records to sort the clients list:

Quicksort.sort(clients)

16. Then, find your search methods and change them from search( ) to search_sorted( )

17. Run the code and add the speeds to your Excel table in the “ArrayList (sorted data)” column.

Deliverables Part 1

· Complete the Module 1 Course Project Presentation deliverable

· TimeProcess.py code

· Client.py code

· ArrayListActualSpeed.py code

· Screenshot showing the code running with your name and date in the output

· Excel “Table of Speeds” table

image3.png

image1.png

image2.emf

Microsoft_Visio_Drawing.vsdx

Client
<<Stereotype>>
parameter
– __client_id
– __first_name
– __last_name
– __phone
– __email
+ __lt__(other) : boolean
+ __eq__( other ) : boolean
+ __str__( ) : string







Calculate Your Essay Price
(550 words)

Approximate price: $22

Calculate the price of your order

550 words
We'll send you the first draft for approval by September 11, 2018 at 10:52 AM
Total price:
$26
The price is based on these factors:
Academic level
Number of pages
Urgency
Basic features
  • Free title page and bibliography
  • Unlimited revisions
  • Plagiarism-free guarantee
  • Money-back guarantee
  • 24/7 support
On-demand options
  • Writer’s samples
  • Part-by-part delivery
  • Overnight delivery
  • Copies of used sources
  • Expert Proofreading
Paper format
  • 275 words per page
  • 12 pt Arial/Times New Roman
  • Double line spacing
  • Any citation style (APA, MLA, Chicago/Turabian, Harvard)

Our guarantees

Delivering a high-quality product at a reasonable price is not enough anymore.
That’s why we have developed 5 beneficial guarantees that will make your experience with our service enjoyable, easy, and safe.

Money-back guarantee

You have to be 100% sure of the quality of your product to give a money-back guarantee. This describes us perfectly. Make sure that this guarantee is totally transparent.

Read more

Zero-plagiarism guarantee

Each paper is composed from scratch, according to your instructions. It is then checked by our plagiarism-detection software. There is no gap where plagiarism could squeeze in.

Read more

Free-revision policy

Thanks to our free revisions, there is no way for you to be unsatisfied. We will work on your paper until you are completely happy with the result.

Read more

Privacy policy

Your email is safe, as we store it according to international data protection rules. Your bank details are secure, as we use only reliable payment systems.

Read more

Fair-cooperation guarantee

By sending us your money, you buy the service we provide. Check out our terms and conditions if you prefer business talks to be laid out in official language.

Read more

Order your essay today and save 10% with the coupon code: best10