Developer-Student-Clubs-VSSUT-Burla / Master-PyAlgo

36 stars 84 forks source link

Substring Extractor #521

Open Manasi2001 opened 3 years ago

Manasi2001 commented 3 years ago

Aim: Consider a database table, Emails, which has the attributes First Name and Email ID. Given N rows of data simulating the Emails table, print an alphabetically-ordered list of people whose email address ends in '@gmail.com'.

Sample Input: 6 riya riya@gmail.com julia julia@julia.me julia sjulia@gmail.com samantha samantha@gmail.com tanya tanya@gmail.com julia julia@gmail.com

Sample Output: julia julia riya samantha tanya

Explanation: Only the names of people having the substring '@gmail.com' in their mail ids are printed.