title: Returning vowels
body: <p>I am a beginner in Java, and I am doing my practice on practiceit.</p>
  
  <p>But I got stumbled over this question.</p>
  
  <p>Write a method named <code>isVowel</code> that returns whether a <code>String</code> is a vowel (a single-letter string containing a, e, i, o, or u, case-insensitively).</p>
  
  <pre><code>public static boolean isVowel(String word){
  
    
     for(int i=0;i&lt;word.length();i++){
    
  
      char vowels=word.charAt(i);
          if(vowels== 'a'|| vowels =='e' || vowels=='i'|| vowels == 'o' ||  vowels == 'u'|| vowels== 'A'|| vowels =='E' || vowels=='I'|| vowels == 'O' ||  vowels == 'U' ){
             return true;
          } 
         
     }
      return false;
  }
  </code></pre>
  
  <p>This code works but when i test it for "hello". It no longer works. I understand it is because the condition is char so it loops one by one and not the word as a whole.But i cant figure out.Will appreciate if someone will give me hints instead of answer.</p>