Input selection algorithm

Rebased to vp-withdrawal.

Note I had to make some minor changes to make the test run again.

Also the createInputs and createInputsStore needs to be cleaned up. They are both taking a store right now and especially the createInputsStore name is misleading.
I find eligible to be a bit too generic a name. My first suggestion would be isCreditEligible(), but in Go everyone seems to not care about the "is" prefix in boolean methods, so maybe just creditEligible()?