image_2021-11-07_04-41-37.png
32.4 KB
#N1832. Check if the Sentence Is Pangram
problem link
#solution
problem link
#solution
class Solution {
public boolean checkIfPangram(String sentence) {
int[] alphabet=new int[26];
for(char ch:sentence.toCharArray()){
alphabet[ch-'a']++;
}
for(int num:alphabet)
if(num==0)
return false;
return true;
}
}