You are viewing a single comment's thread. Return to all comments →
public static string pangrams(string s) { s = s.ToLower(); int[] alphabet = new int[26]; foreach(char c in s){ if(c >= 'a' && c <='z'){ alphabet[(int)c - (int)'a']++; } } return alphabet.Any(c => c == 0) ? "not pangram" : "pangram"; }
Seems like cookies are disabled on this browser, please enable them to open this website
Pangrams
You are viewing a single comment's thread. Return to all comments →