Removing weight as attribute of argument. Fixing def of acceptable().
Refactored weighting to conform to Haskell approach