Write program in C++ using strings in conjuction with 2D arrays. Allow the user to enter the names of several local businesses. Sort the business names and display the results. Continue this process until the user is out of business names. Please use good functional decomposition to make your development easier. (Perhaps one function for sorting an array of strings, another function for swapping two strings, one for displaying an array of strings, and others to maintain the user interface. This is also a good place to use a library, btw.) Example Run As an example the program interaction might look something like (the parts in parentheses are typed by the user): $ ./busisort.out        Welcome to the Business Sorting Program!!! Please enter the name of a business: (WalMart) Your business is: WalMart Another business? (y) Please enter the name of a business: (JC Penney) Your businesses are: JC Penney WalMart Another business? (Y) Please enter the name of a business: (Merlin Muffler) Your businesses are: JC Penney Merlin Muffler WalMart Another business? (yes) Please enter the name of a business: (Appleby's) Your businesses are: Appleby's JC Penney Merlin Muffler WalMart Another business? (Yes) Please enter the name of a business: (Zippy's) Your businesses are: Appleby's JC Penney Merlin Muffler WalMart Zippy's Another business? (no) Thank you for using the BSP!! Endeavor to have an egregious day! $

New Perspectives on HTML5, CSS3, and JavaScript
6th Edition
ISBN:9781305503922
Author:Patrick M. Carey
Publisher:Patrick M. Carey
Chapter14: Exploring Object-based Programming: Designing An Online Poker
Section14.1: Visual Overview: Custom Objects, Properties, And Methods
Problem 7QC
icon
Related questions
Question

Write program in C++ using strings in conjuction with 2D arrays.

Allow the user to enter the names of several local businesses. Sort the business names and display the results. Continue this process until the user is out of business names.

Please use good functional decomposition to make your development easier. (Perhaps one function for sorting an array of strings, another function for swapping two strings, one for displaying an array of strings, and others to maintain the user interface. This is also a good place to use a library, btw.)

Example Run

As an example the program interaction might look something like (the parts in parentheses are typed by the user):

$ ./busisort.out

       Welcome to the Business Sorting Program!!!

Please enter the name of a business: (WalMart)

Your business is: WalMart

Another business? (y)

Please enter the name of a business: (JC Penney)

Your businesses are: JC Penney WalMart

Another business? (Y)

Please enter the name of a business: (Merlin Muffler)

Your businesses are: JC Penney Merlin Muffler WalMart

Another business? (yes)

Please enter the name of a business: (Appleby's)

Your businesses are: Appleby's JC Penney Merlin Muffler WalMart

Another business? (Yes)

Please enter the name of a business: (Zippy's)

Your businesses are: Appleby's JC Penney Merlin Muffler WalMart Zippy's

Another business? (no)

Thank you for using the BSP!!

Endeavor to have an egregious day!

$

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps with 4 images

Blurred answer
Knowledge Booster
Array
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
New Perspectives on HTML5, CSS3, and JavaScript
New Perspectives on HTML5, CSS3, and JavaScript
Computer Science
ISBN:
9781305503922
Author:
Patrick M. Carey
Publisher:
Cengage Learning