Hi,
Can anyone please let me know, how to find out the number of vowels in a string?
Thank you in advance
Discussion posts and replies are publicly visible
Hi, Check the below code
a!localVariables( local!text: "Television", local!vowels: { "a", "e", "i", "o", "U" }, local!getVowels: a!forEach( items: char(code(local!text)), expression: if( contains(local!vowels, lower(fv!item)), fv!item, {} ) ), length(local!getVowels) )
Its not counting all the vowels, only first vowel is get counted