How to I count multiple values in hash into a new hash?
My current hash: %hash = ( "foo", [ "apple", "orange", "apple", "apple" ], "bob", [ "apple", "orange", ], ); How do I obtain this output? %hash2 = ( apple => 4, orange => 2, );
0 upvotes
View original discussion ↗
Comments
Sign in or sign up to comment and upvote.
No comments yet.