IDEAS home Printed from https://ideas.repec.org/a/aes/infoec/vxy2006i4p29-33.html
   My bibliography  Save this article

Cashier Problem: a Greedy Algorithm and an optimal Solution

Author

Listed:
  • Nicolae GIURGITEANU

Abstract

We will remind briefly the cashier problem. A cashier has leeway a range of different fractional coins and has to pay a certain amount using the most reduced number of coins. If we mark the pay-desk monetary with P {p ,..., pn } 1 = , each pi having as denomination di and with A the final sum, the cashier must determine a coins subset { } m S q ,..., q 1 = of P, so that i m i id q A Σ==1. In order to solve this problem, there are several solutions consisting in greedy algorithms. Although there is an optimal solution, in the present article we will highlight a greedy algorithm and an optimal solution for this problem. The solution known at the time being use a lot of memory and, in addition, is difficult to justify, occurring the risk of misunderstanding by the reader. Our solution is simpler and uses little memory

Suggested Citation

  • Nicolae GIURGITEANU, 2006. "Cashier Problem: a Greedy Algorithm and an optimal Solution," Informatica Economica, Academy of Economic Studies - Bucharest, Romania, vol. 0(4), pages 29-33.
  • Handle: RePEc:aes:infoec:v:x:y:2006:i:4:p:29-33
    as

    Download full text from publisher

    File URL: http://www.revistaie.ase.ro/content/40/giurgiteanu.pdf
    Download Restriction: no
    ---><---

    Corrections

    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:aes:infoec:v:x:y:2006:i:4:p:29-33. See general information about how to correct material in RePEc.

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    We have no bibliographic references for this item. You can help adding them by using this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: Paul Pocatilu (email available below). General contact details of provider: https://edirc.repec.org/data/aseeero.html .

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service. RePEc uses bibliographic data supplied by the respective publishers.