Q: To check whether the given string contains all the vowels in english language.
Input
- Length of String
- And the String
Output
YES/NOImplementation
Implemented using Python SetsCode
size=raw_input();
st=raw_input();
flag=0
vowel=set()
mylist=['a','e','i','o','u']
for i in range(int(size)):
 if st[i] in mylist:
  vowel.add(st[i])
  if len(vowel)==5:
   print "YES"
   flag=1
   break
 
if flag==0: 
 print "NO"
 

 
No comments:
Post a Comment