Ad
  • Custom User Avatar

    I realized after many attempts that the key to everything is to keep track of the nr of banknotes and not the change available.

    Anyway, these should be useful tests to run your sw against:

    tickets([25,50,50]) > 'NO'
    tickets([25,50,25,50]) > 'YES'
    tickets([25,25,25,25,50,100,50]) > 'YES'