In  this tutorial, we will see “How to check if ‘VOWEL’ is present in a String using Java 8?” check vowel in string using java 8

Java 8 – How to check if VOWEL is present in a String? – Simplest Example Share on X

 

Output:

check vowel in string java 8

In this example, IntStream.range method is used to create a stream of integers from 0 to s.length() - 1, the mapToObj method to map each integer to the corresponding character in the string, and the anyMatch method is there to check if any of the characters are vowels. and Finally, the indexOf method is used to check if a character is a vowel.

skip method java 8 stream

Java 8 – How to check if VOWEL is present in a String? – Simplest Example Share on X

Do you like this Post? – then check my other helpful posts:

Other Useful References:

Author

  • Deepak Verma

    Deepak Verma is a Test Automation Consultant and Software development Engineer for more than 10 years. His mission is to help you become an In-demand full stack automation tester. He is also the founder of Techndeck, a blog and online coaching platform dedicated to helping you succeed with all the automation basics to advanced testing automation tricks.

    http://Techndeck.com deepak.rkgit@gmail.com Verma Deepak