A script to simplify people paying each other for items in groups. Algorithm co-conceived with Tom McLaughlin.
How to use
Run as follows
$ runhaskell payments.hs < input.txt
Input file format
You need an input file where each line conforms to the following format (where the '
<' and '
>' aren't in your file; they're just delimiters for purposes of describing input):
<item_name> <payer_name> <list_of_recipients_of_item> <cost>
Each segment (e.g. ) can have no spaces, and must be a number. Additionally, must be of the following format:
, where there are no spaces after the commas, and the '
[' and '
]' are present.
input.txt for an example.