Check if the Sentence Is Pangram

PHOTO EMBED

Sat Oct 08 2022 13:48:29 GMT+0000 (Coordinated Universal Time)

Saved by @Ranjan_kumar #c++

class Solution {
public:
    bool checkIfPangram(string s) {
        int n=s.size();
        vector<bool> v(26,false);
        if(n<26) return false;
        else if(n>=26)
        {
            for(int i=0;i<n;i++)
            {
                v[s[i]-'a']=true;
            }
        }
        for(int i=0;i<26;i++)
        {
            if(v[i]==false) return false;
        }
        return true;
    }
};
content_copyCOPY

https://leetcode.com/problems/check-if-the-sentence-is-pangram/