Ruby - how to group data in object?
I am receiving data in this format:
{2013-09-13 22:55:56 UTC=>1, 2013-09-15 13:14:19 UTC=>1, 2013-09-16
13:05:39 UTC=>1, 2013-09-16 19:12:44 UTC=>1}
I would need to group them according to day, to this shape:
{2013-09-13=>1, 2013-09-15=>1, 2013-09-16=>2}
How to do this in Ruby?
Thanks
No comments:
Post a Comment