Map || C++ Solution
\nclass Solution {\npublic:\n\n    int find(string str)\n{\n         int count = 0;\n         int temp = 0;\n        int i=0;\n       \n   while (i!=str.length(
```\nclass Solution {\npublic:\n\n    int find(string str)\n{\n         int count = 0;\n         int temp = 0;\n        int i=0;\n       \n   while (i!=str.length()){\n      if (str[i] == \' \' || str[i] == \'\\n\' || str[i] == \'\\t\'){\n         temp = 0;\n      }\n      else if(temp == 0){\n         temp = 1;\n         count++;\n      }\n      i++;\n   }\n   return count;\n}\n    string largestWordCount(vector<string>& messages, vector<string>& senders) {\n        \n        //Map will sort senders lexicographically  \n        map<string,string> umap;\n        string ans="";\n        int count=0;\n        for(int i=0;i<messages.size();i++)\n        {\n            if(umap[senders[i]]!="")\n                umap[senders[i]]+=" ";\n            umap[senders[i]]+=messages[i];\n        }\n        for(auto i=umap.begin();i!=umap.end();i++)\n        {\n            //Count Number of words for each Senders\n            int c=find(i->second);\n            //If count of words is greater than the last word count\n            //Note: Map has already sorted Senders lexicographically\n            if(c>=count)\n            {\n                count=c;\n                ans=i->first;\n            }\n        }\n        return ans;\n    }\n};\n```\n**Like it? Please Upvote ;-)**
['C', 'C++']