Question: Write a C++ program count.cpp : common.h Basic results look like this args.cpp Enhanced results look like this 1. Complete counts.cpp using the tools provided
1. Complete counts.cpp using the tools provided in common.h a follows: o Read characters from standard input until EoF (the end-of-file mark) is read (see the textbook page 353, and know that cin has most of the same features as input file streams. Do not prompt the user to enter text just read data as soon as the program starts. o Keep a running count of each different character encountered in the input, and keep count of the total number of characters input. Note there are a total of 128 ASCILcodes, equal to the value of the symbolic constant NUM defined in common.h. Get familiar with the features of common.h many of them are andy, and you will be required to use some of them in later steps. o Print a neat table that shows each different input code, the corresponding character and its count, and print the total count at the end. Do not print any rows for ASCII codes that are not included in the input text. o You must exactly match the format of our solution's basic results, and so you must use the symbols and functions defined in common.h. Do NOT print anything any other way. o Use pr Header one time at the start. o Use prcountstr for each row that corresponds to a special character (codes 0-32, and 127), and use the symbol strings provided in common.h o Use prcountChr for each row that corresponds to a printable character (codes 33-126) o Use prTotal one time at the end
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
