C++ question 1.) Write an iterative routine that will take a string, go through each character of the string and enqueue the character if it is a punctuation (.,?!), else toss the character. When end of string is reached, then dequeue the characters, count how many punctuations are there, then print the count.

C++ Programming: From Problem Analysis to Program Design
8th Edition
ISBN:9781337102087
Author:D. S. Malik
Publisher:D. S. Malik
Chapter17: Linked Lists
Section: Chapter Questions
Problem 16PE
icon
Related questions
Question

C++ question

1.) Write an iterative routine that will take a string, go through each character of the string and enqueue the character if it is a punctuation (.,?!), else toss the character. When end of string is reached, then dequeue the characters, count how many punctuations are there, then print the count.

2.) Write a routine that would receive a pointer to the top of the linked list that has an integer for each node. Change all odd integers to even by adding one. But count the numbers you changed and print the count.

Expert Solution
steps

Step by step

Solved in 5 steps with 3 images

Blurred answer
Knowledge Booster
Algebraic Expressions
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
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning