Given an array of strings, return all groups of strings that are anagrams.
注意
All inputs will be in lower-case
样例
Given a string list: ["lint","intl","inlt","code"]
return ["lint","inlt","intl"]
标签 Expand
Hash
Table String
public class Solution {
/**
* @param strs: A list of strings
* @return: A list of strings
*/
public List<String> anagrams(String[] strs) {
Map<String,Integer> map = new HashMap<String,Integer>()......
阅读全文