Use Enumerable#reduct over #inject