What this calculator does
Solve how many coins of two denominations make a known coin count and total value.
How it works
The calculator evaluates x + y = total coins; valueA·x + valueB·y = total cents. Inputs are checked before calculation, and invalid values such as zero denominators or out-of-range selections produce a clear error instead of a misleading result.
Input query strings and outputs
Use an input name in this page’s URL as ?name=value, and join additional inputs with &. Portable shared links may instead use the compact ?ac= state parameter.
Input query strings
4-
?coinAValue=Coin A value (cents)Number · Required · Default: 10
-
?coinBValue=Coin B value (cents)Number · Required · Default: 25
-
?totalCoins=Total number of coinsNumber · Required · Default: 20
-
?totalValue=Total value ($)Number · Required · Default: 3.5
Outputs
3-
coinACountCoin A countWhole number · Primary output
-
coinBCountCoin B countWhole number
-
checkValueValue checkCurrency
Inputs and results
The inputs are Coin A value (cents), Coin B value (cents), Total number of coins, Total value ($). Results include Coin A count, Coin B count, Value check.