Improve coding style of two short completed algorithms


First and foremost, focus on improving your variable names as this will likely have the biggest positive effect for readability. Next, you should focus on breaking larger pieces of code into smaller functions that serve one specific purpose. These should also have good names that explain what they do. Finally, if you notice any part of the code that is repeated, place that in a function and call the function instead of repeating the same block of code in multiple places. Your ultimate goal should be to make the code more readable.

Don't use plagiarized sources. Get Your Custom Essay on
Improve coding style of two short completed algorithms
Just from $10/Page
Order Essay

Try to follow pep8 guidelines. I’ll also attach the original questions that lead to the algorithm for logical continuity in the following.

Original Question (resource):

An ascending clock auction is an auction where the seller starts bidding at a low price and gradually raises the price as the auction progresses. As the price increases, bidders can choose to stay in the auction (bid for the item at the clock price) or drop out and forgo their chance at winning the item. The clock price is usually raised by a fixed discrete increment. The auction ends when there is only one bidder remaining. The winning bidder gets the item and pays the posted price (clock price from the last round with multiple bidders).

Example: A seller is auctioning off a baseball card. The starting auction price is $10 and the clock increment is $1. In the first round of bidding there are 5 people who place bids of $10. The seller then raises the price to $11 and bidding continues until there is only one bidder willing to pay the clock price. Say this continues until the clock price is $15 and there are two bidders left. If one bidder drops out, the remaining bidder wins the baseball card and pays the posted price of $14.

You will need to write a Monte Carlo simulation to estimate the seller revenue from an ascending clock auction. For this assignment, assume the following parameters:

  • There are 5 buyers
  • Buyer values are drawn between 0 and 100 in increments of 5
  • Seller reserve prices are allowed to be between 0 and 100 in increments of 5
  • The item is considered sold when the clock price is greater than or equal to the reserve price
  • The auction ends when there is one or less buyers bidding at the clock price.
  • In the case of two buyers dropping out at the same price, you can go back to the previous price and randomly choose the winning buyer.
  1. What is the expected revenue if there are 5 buyers and the clock increment is $1?
  2. What is the expected revenue if there are 5 buyers and the clock increment is $10? How did the increment affect the expected revenue and why does it have that effect?
  3. What is the expected revenue if there are 20 buyers with a clock increment of $1? Compare with item (a) and explain the difference.

Let’s extend our Monte Carlo simulation of the ascending clock auction to allow the seller to choose a reserve price. A reserve price is the minimum price a seller is willing to accept to sell the item. If the final clock price is below the reserve price the seller receives zero revenue. This means the auction now ends when either there are zero buyers bidding at the current clock price, or there is one buyer bidding and the reserve price has been met.

D. What reserve price should the seller choose (which price generates the most revenue)? Provide an illustration that supports your result.

Get professional assignment help cheaply

Are you busy and do not have time to handle your assignment? Are you scared that your paper will not make the grade? Do you have responsibilities that may hinder you from turning in your assignment on time? Are you tired and can barely handle your assignment? Are your grades inconsistent?

Whichever your reason may is, it is valid! You can get professional academic help from our service at affordable rates. We have a team of professional academic writers who can handle all your assignments.

Our essay writers are graduates with diplomas, bachelor, masters, Ph.D., and doctorate degrees in various subjects. The minimum requirement to be an essay writer with our essay writing service is to have a college diploma. When assigning your order, we match the paper subject with the area of specialization of the writer.

Why choose our academic writing service?

  • Plagiarism free papers
  • Timely delivery
  • Any deadline
  • Skilled, Experienced Native English Writers
  • Subject-relevant academic writer
  • Adherence to paper instructions
  • Ability to tackle bulk assignments
  • Reasonable prices
  • 24/7 Customer Support
  • Get superb grades consistently


Order a unique copy of this paper
(550 words)

Approximate price: $22

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

We value our customers and so we ensure that what we do is 100% original..
With us you are guaranteed of quality work done by our qualified experts.Your information and everything that you do with us is kept completely confidential.

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

The Product ordered is guaranteed to be original. Orders are checked by the most advanced anti-plagiarism software in the market to assure that the Product is 100% original. The Company has a zero tolerance policy for plagiarism.

Read more

Free-revision policy

The Free Revision policy is a courtesy service that the Company provides to help ensure Customer’s total satisfaction with the completed Order. To receive free revision the Company requires that the Customer provide the request within fourteen (14) days from the first completion date and within a period of thirty (30) days for dissertations.

Read more

Privacy policy

The Company is committed to protect the privacy of the Customer and it will never resell or share any of Customer’s personal information, including credit card data, with any third party. All the online transactions are processed through the secure and reliable online payment systems.

Read more

Fair-cooperation guarantee

By placing an order with us, you agree to the service we provide. We will endear to do all that it takes to deliver a comprehensive paper as per your requirements. We also count on your cooperation to ensure that we deliver on this mandate.

Read more

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:
The price is based on these factors:
Academic level
Number of pages
Open chat
You can contact our live agent via WhatsApp! Via +1 817 953 0426

Feel free to ask questions, clarifications, or discounts available when placing an order.

Order your essay today and save 20% with the discount code VICTORY