Answered step by step
Verified Expert Solution
Question
1 Approved Answer
please program in c++ Program Requirements Write a program that does the following: 1. Read a string (a C-style char array) from the user through
please program in c++
Program Requirements Write a program that does the following: 1. Read a string (a C-style char array) from the user through the console o You can assume that the user will not enter more than 40 characters *Remember that 1 more character is needed for the null string terminator The user may enter letters (lowercase or uppercase), digits, or symbols (", :@.#,, etc.) 2. Copy all the letters from the input string into a new array, and copy all the digits from the input string into another new array (see Figure 1) Each new array must be dynamically allocated to the exact size needed to hold all of the letters or digits, plus one final location that must be set to the null string terminator character You can use the isalpha() and isdigit() functions (#includeStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started