Group Anagrams
Given an array of strings strs, group the anagrams together. You can return the answer in any order.

30:00

Group Anagrams
medium
Topics
Companies

Given an array of strings strs, group the anagrams together. You can return the answer in any order.

Example 1:
Input: ["eat","tea","tan","ate","nat","bat"]
Output: [["eat","tea","ate"],["tan","nat"],["bat"]]
Constraints:
  • 1strs.length1041 \leq \text{strs.length} \leq 10^4

  • 0strs[i].length1000 \leq \text{strs}[i].\text{length} \leq 100

  • strs[i] consists of lowercase English letters.

Input
arr =["eat","tea","tan","ate","nat","bat"]
Input Array
eat
tea
tan
ate
nat
bat
Anagram Groups (HashMap)
Variables
No variables to display
DepthFunction Call
1groupAnagrams(strs=[6])
0/19