Question: Make a function read the file() that reads animal names from a file animal.txt into an array[]. ask the user to enter the name of

 Make a function read the file() that reads animal names from a file animal.txt into an array[]. ask the user to enter the name of an animal into the name[]. Make a function check() that accepts array[] and animal that checks if the animal entered by the user is present in the file or not. Display the output on the console.





Sample Output:

Animal.txt: ratcowelephanthorselion Output: Enter the name of an animal: horse Animal found


Animal.txt: ratcowelephanthorselion Output: Enter the name of an animal: horse Animal found

Step by Step Solution

3.39 Rating (155 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

implement using c FindAnimalcpp include i... View full answer

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 Programming Questions!