string

C/C++ Program to count the number of vowels and consonants in a string using pointers

Write a program in C/C++ to count the number of vowels and consonants in a string using pointers. Example, Input MyNameIsJohnSmith Output Consonants: 12 Vowels: 5 Steps Let str[] be the input string. Initialize c1 = 0 and c2 = 0. c1 stores the number of consonants and c2 stores the number of vowels. Read …

C/C++ Program to count the number of vowels and consonants in a string using pointers Read More »