funcifyr.js
function(prop) {
        return function tallied(arrayOfObjects) {
          return arrayOfObjects.reduce(function(acc, curr) {
            acc[curr[prop]] = (acc[curr[prop]] || 0) + 1;
            return acc;
          }, {});
        }
      }
function(prop) {
        return function tallied(arrayOfObjects) {
          return arrayOfObjects.reduce(function(acc, curr) {
            acc[curr[prop]] = (acc[curr[prop]] || 0) + 1;
            return acc;
          }, {});
        }
      }
function ( prop ) { return function tallied ( arrayOfObjects ) { return arrayOfObjects . reduce ( function ( acc , curr ) { acc [ curr [ prop ] ] = ( acc [ curr [ prop ] ] || 0 ) + 1 ; return acc ; } , { } ) ; } }
Returns an object with the number of occurrences of a property value found in an array of objects.

tally :: (a) → (arr) → obj

@param prop - A string representation of a property to target
@returns function
@param arrayOfObjects - An array of objects
@returns An object with the prop as a key, and the number of its occurences as the value
Returns an object with the number of occurrences of a property value found in an array of objects .