Coders Packet

python program to display the vowels and consonants present in his/her name

By Karthik Nagisetty

In English language the vowels and consonants are the types of letters divided based on their pronounce.

vowels and consonents using pythonpython program to display the vowels and consonants present in his/her name

In the English language, the types of letters are divided into two types. They are:

1. Vowels

2. consonants

Based on the letters pronounced and sounds, the letters are divided. Among 26 Alphabets, the vowels are 5 letters and the consonants are 21 letters. The vowels are[a,e, I,o,u] and the remaining [b,c,d,f,g,h,j,k,l,m,n,p,q,r,s,t,v,w,x,y,z] are the consonants.

In this project, we will find the vowels and consonants in the given name using Python programming. The input is giving a name and the output is the classification of vowels and consonants in the given input name.

 

 

def Check_vow(string,vowels):
    vowel=[]
    cons=[]
    for each in string:
        if each in vowels:
            vowel.append(each)
        else:
            cons.append(each)
    print('Number of vowels',len(vowel))
    print('Vowels are',vowel)
    print('Number of consonants',len(cons))
    print('Consonats are',cons)
#Driver Code string=input("Enter first name of student:").lower() vowels='aeiou' Check_vow(string,vowels)

 

 

 

 

Download Complete Code

Comments

No comments yet

Download Packet

Reviews Report

Submitted by Karthik Nagisetty (karthik)

Download packets of source code on Coders Packet