Skip to content

Commit 41bb691

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 5b66a24 commit 41bb691

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

backtracking/inverse_coin_change.py

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
def inverse_coin_change(amount, coins):
22
"""
33
Finds all combinations of coins that sum up to the given amount.
4-
4+
55
:param amount: Target amount
66
:param coins: List of coin denominations
77
:return: List of combinations (each combination is a list of coins)
@@ -28,8 +28,12 @@ def main():
2828
import argparse
2929

3030
parser = argparse.ArgumentParser(description="Inverse Coin Change Solver")
31-
parser.add_argument("--amount", type=int, required=True, help="Target amount to reach")
32-
parser.add_argument("--coins", type=int, nargs="+", required=True, help="List of coin denominations")
31+
parser.add_argument(
32+
"--amount", type=int, required=True, help="Target amount to reach"
33+
)
34+
parser.add_argument(
35+
"--coins", type=int, nargs="+", required=True, help="List of coin denominations"
36+
)
3337

3438
args = parser.parse_args()
3539

0 commit comments

Comments
 (0)