Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Make a C program that will have two functions. Your first function will ask the user to enter a sentence. This sentence will have the

Make a C program that will have two functions. Your first function will ask the user to enter a sentence. This sentence will have the number of ys in it counted by your second function. You must count both capital and non-capital ys (and remember that in C the small y and the big Y are two different characters). Your second function will then return the number of ys to your first function. Your first function will then print the sentence back to the user along with the number of ys that were found in the sentence.

Output Example:

Create a sentence:

You checked everywhere yet you could not find your plush toy.

Sentence user entered:

You checked everywhere yet you could not find your plush toy.

The number of ys in this sentence is 6

You cannot use fgets (use scanf). Try using a one-dimensional array for this question.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

SQL Antipatterns Avoiding The Pitfalls Of Database Programming

Authors: Bill Karwin

1st Edition

1680508989, 978-1680508987

More Books

Students also viewed these Databases questions

Question

=+c. Determine the payback period.

Answered: 1 week ago