We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
we should use replace instead of split and join because we are performing single o(n) operation instead of performing 2 o(n) operations. also, we save memory as split would create an array
C++
Java
Fastest and Most Efficient Implementation Possible
Alternative Way checking Bitmask Equality
def pangrams(s): return 'pangram' if len(set(s.lower().replace(' ', ''))) == 26 else 'not pangram'
we should use replace instead of split and join because we are performing single o(n) operation instead of performing 2 o(n) operations. also, we save memory as split would create an array