||EASY||SIMPLE||JAVA||
\n\n# Code\n\nclass Solution {\n    public int maximumNumberOfStringPairs(String[] words) {\n        int count =0;\n        HashMap<String,Integer> arr = new Ha
\n\n# Code\n```\nclass Solution {\n    public int maximumNumberOfStringPairs(String[] words) {\n        int count =0;\n        HashMap<String,Integer> arr = new HashMap<>();\n\n        for(int i=0 ;i<words.length;i++){\n             String r = new StringBuilder(words[i]).reverse().toString();\n            if(arr.containsKey(r)){\n                arr.put(r, arr.get(r)+1);\n            }\n            else{\n                arr.put(words[i],0);\n            }\n        }\n\n        for(int j : arr.values()){\n            count += j;\n        }\n        return count;\n    }\n}\n```
['Java']