About 18,700,000 results
Open links in new tab
  1. currency - Figuring out money change in python - Stack Overflow

    Sep 19, 2018 · I wrote the code for you and this is how it works. Basically it sees each currency and uses integer division // to see how many integers can fit in. It then subtracts that amount from the remaining change and the process continues.

  2. python - Work out correct money denominations for change - Stack Overflow

    Jul 25, 2013 · What I'd like to do is breakdown the amount_change into the money denominations that I have and return the change to the client with the correct notes and or coins. My denominations are [200, 100, 50, 20, 10, 5, 1, 0.5]

  3. python - What class to use for money representation ... - Stack Overflow

    Jul 30, 2013 · You could have a look at this library: python-money. Since I've no experience with it I cannot comment on its usefullness. A 'trick' you could employ to handle currency as integers: Multiply by 100 / Divide by 100 (e.g. $100,25 -> 10025) to have a representation in 'cents'

  4. How to Handle Monetary Values in Python - Medium

    Sep 17, 2024 · There are two basic approaches to dealing with monetary values. Let’s consider the first approach — to use the Integer type for work. The idea is to multiply a monetary value by a factor...

  5. How to Count Money Exactly in Python - LearnPython.com

    Oct 21, 2021 · Counting Money in Python: Where to Now? We have reviewed the use of the decimal module to count money in Python, but there are also other Python modules worth mentioning. For example, fractions supports exact calculations by implementing rational-number-based arithmetic.

  6. GitHub - ListfulAl/PreciseMoney: A Python library for handling …

    Here's a simple example of how to use the precise_money Library: usd_30 = Money. from_currency ("USD", "30.00")

  7. Building a Currency Converter Application using Tkinter - Python

    Apr 25, 2025 · In the above code, we import the os and sys modules from the Python standard library. Then, we import the tkinter package as tk.This shorthand is typically used with Tkinter to save repeatedly typing the full name. We also import the tkinter.ttk package which gives us access to Tkinter's themed widgets, which looker nicer than the defaults. We also import Tkinter's messagebox module for ...

  8. How to Make Money with Python: 7 Tried-and-Tested Ways

    How to make money with Python? You can make money with Python programming skills in the following ways. Get a Developer Job; Create a StartUp; Freelancing; Teach Coding Online; Create a YouTube channel and Monetize it; Create a Blog and Monetize it; Join Coding Contests; Let’s discuss each one of these methods in detail. 1. Get a Developer Job

  9. Representing money in Python · Bits and pieces - GitHub Pages

    Jan 13, 2019 · As mentioned, the Decimal class provides the ability to correctly represent an amount of money and basic arithmetic support. However Decimal misses the possibility to specify a currency and implement the correct handling. Luckily there are a few packages available which wrap the Decimal class: py-money

  10. How to Manage Money with Python - The Python Code

    Explore how Python, a versatile and user-friendly programming language, enhances money management through budgeting, expense tracking, and investment analysis. This guide delves into Python's financial tools and libraries for effective financial planning and automation, ensuring secure and informed financial decisions.

  11. Some results have been removed
Refresh