validAllocation function
Implementation
bool validAllocation(Map<String,int> answer,List<String> items,int total)=>answer.length==items.length&&answer.keys.every(items.contains)&&answer.values.every((value)=>value>=0&&value<=total)&&allocationRemaining(total,answer)==0;