Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Declare a string array of size 5. Use a loop to store five fruits in the array that are entered by the user. Then find

Declare a string array of size 5. Use a loop to store five fruits in the array that are entered by the user. Then find the longest string in the array and output it. Hint: Use .length() on a string variable to determine the number of chars in a string. Sample Run: Fruit 1: banana Fruit 2: apple Fruit 3: lemon Fruit 4: pears Fruit 5: orange Longest: banana

can anyone answer this in c++

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

Relational Database And SQL

Authors: Lucy Scott

3rd Edition

1087899699, 978-1087899695

More Books

Students also viewed these Databases questions