Hello C++ question thank you   1) Develop a function that properly prints out each element of a vector of strings   Print an endline character when done to make sure the next print starts on a new line make this function templated to the vector type passed in(Comment this) 2) Implement the following functionality using std::vector and std::string data types: a vector that contains the following strings as elements { olleh ereht skool ekil uoy desrever gnihtyreve gnidrocca ot nalp doog boj } Print the vector using your function Reverse all the letters in each string, so that each string is now a proper word Print the vector using your function a second "new" vector, copying the first vector's elements using iterators Do not copy the first two elements and the last two elements into the new vector Print the "new" vector using your function Sort the "new" vector alphabetically Print the "new" vector using your function Change every 'o' character in the "original" vector into a '@' character Print the "original" vector using your function

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question
100%

Hello C++ question thank you

 

1) Develop a function that properly prints out each element of a vector of strings
 

  • Print an endline character when done to make sure the next print starts on a new line
  • make this function templated to the vector type passed in(Comment this)

2) Implement the following functionality using std::vector and std::string data types:

  • a vector that contains the following strings as elements { olleh ereht skool ekil uoy desrever gnihtyreve gnidrocca ot nalp doog boj }
  • Print the vector using your function
  • Reverse all the letters in each string, so that each string is now a proper word
  • Print the vector using your function
  • a second "new" vector, copying the first vector's elements using iterators
    • Do not copy the first two elements and the last two elements into the new vector
  • Print the "new" vector using your function
  • Sort the "new" vector alphabetically
  • Print the "new" vector using your function
  • Change every 'o' character in the "original" vector into a '@' character
  • Print the "original" vector using your function
Expected Program Output
olleh ereht skool ekil uoy desrever gnihtyreve gnidrocca ot nalp doog boj
hello there looks like you reversed everything according to plan good job
looks like you reversed everything according to plan
according everything like looks plan reversed to you
hell@ there l@@ks like y@u reversed everything acc@rding te plan g@@d jeb
Transcribed Image Text:Expected Program Output olleh ereht skool ekil uoy desrever gnihtyreve gnidrocca ot nalp doog boj hello there looks like you reversed everything according to plan good job looks like you reversed everything according to plan according everything like looks plan reversed to you hell@ there l@@ks like y@u reversed everything acc@rding te plan g@@d jeb
Expert Solution
steps

Step by step

Solved in 4 steps with 2 images

Blurred answer
Follow-up Questions
Read through expert solutions to related follow-up questions below.
Follow-up Question

make this function templated to the vector type passed in. How do I do that?

Solution
Bartleby Expert
SEE SOLUTION
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
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education