Question: Using Python Implement function names() that takes no input and repeatedly asks the user to enter the first name of a student in a class.

Using Python

Implement function names() that takes no input and repeatedly asks the user to enter the first name of a student in a class. When the user enters the empty string, the function should print for every name the number of students with that name.

>>> names()

Enter next name: Valerie

Enter next name: Bob

Enter next name: Valerie

Enter next name: Bob

There are 2 students named Bob

There are 2 students named Valerie

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!