Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 152705
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T09:40:16+00:00 2026-05-11T09:40:16+00:00

I have to following problem to solve. I have to calculate the bidding price

  • 0

I have to following problem to solve. I have to calculate the bidding price from a total price. For example, a client wants to pay 2000$ as a total price, but from this price, there are added costs:

-usage price which is 10% from the bidding price with a minimum of 10$ and a maximum of 50$

-seller price: 2% from bidding price

-added price: 5$ for a bid between 1 and 500 10$ for a bid between 501 and 1000 15$ for a bid between 1001 and 3000 20$ for a bid over 3000$

-storing cost: 100$

from all this, I have to calculate the bidding price for a total of 2000$, for example. I kind of have no clue of how this can be done. Can anyone give me some hints or pieces of answer of what the algorithm should be?

EDIT: ok I got how to calculate the algebra, now where i’m stuck is how to write the algorithm in code or pseudo-code. Anyone got a hint?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-11T09:40:17+00:00Added an answer on May 11, 2026 at 9:40 am

    You can express all those costs as a function of the bid price. Generate a giant equation that is the sum of all those functions and solve for a particular final value, e.g.:

    usage cost(bid) = PIN(bid*0.10, 10, 50) seller cost(bid) = bid*.02 added cost(bid) = PIN(ceiling(bid/500)*5, 5, 10) + PIN(ceiling((bid - 1000)/2000)*5, 0, 10) storing cost(bid) = 100 

    So the final cost is something like:

    final cost(bid) = PIN(bid*.1, 10, 50) + pin(ceiling(bid/500)*5, 5, 20) + PIN(ceiling((bid - 1000)/2000)*10, 0, 20) + bid*.02 + 100 + bid 

    Solve for a particular value and you’re done.

    For example, if you want the total cost to be $2000:

    2000 = PIN(bid*.1, 10, 50) + pin(ceiling(bid/500)*5, 5, 10) + PIN(ceiling((bid - 1000)/2000)*5, 0, 10) + bid*.02 + 100 + bid. 

    Bid must be at least > 1500 and < 2000, which works out nicely since we can make those PIN sections constant:

    2000 = 50 + 10 + 5 + 100 + bid*1.02 1835 = bid*1.02 bid = 1799.0196078431372549019607843137 

    The PIN expressions are the hardest to factor out, so you might have to guess a few times until you get something that narrows down the range of bids you want to calculate.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 66k
  • Answers 66k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • added an answer It's good for situations where you don't have access to… May 11, 2026 at 11:31 am
  • added an answer That information isn't enough to get you a stack trace,… May 11, 2026 at 11:31 am
  • added an answer I'd rather spend a couple of grand and run TFS,… May 11, 2026 at 11:31 am

Related Questions

I have the following problem: I open the dialog, open the SIP keyboard to
I have the following query of linq to entities. The problem is that it
I have to following code: http://www.nomorepasting.com/getpaste.php?pasteid=22987 If PHPSESSID is not already in the table
(All of the following is to be written in Java) I have to build
I have to check a number if it satisfies the following criteria: in binary,
I have code similar to the following in many places: var dbParams = db.ReadParams(memberID,
I have something similar to the following method: public ActionResult Details(int id) { var
Given the following example, why do I have to explicitly use the statement b->A::DoSomething()
I have ASP.Net code similar to the following (this is inside a FIELDSET): <ol>
I have an excel spreadsheet in a format similar to the following... | NAME

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.