Question: Write a code in C++ with a CLASS and member functions THAT TAKES A CPP FILE AS INPUT AND FIND NUMBER OF LINES OF CODE
Assignment:Write a program to count the total program LOC, the total LOC in each proxy the program contains, and the number of methods in each proxy. Notes:- Your program should accept as input the name of a file that contains source code. You are to read the file and count the number of lines of code per proxy according to your LOC Counting Standard. You may assume that the source code adheres to your LOC Coding Standard, e.g., this program should not detemine if the coding standard has been followed Your program should produce output following the general format below. Please do not clutter your submitted test results with extraneous output. Program Proxy Name Number of Methods Proxy LOC Total LOC 1 Average 10 30 25 Main 102 2 InputLine Token Main 30 20 75 3 Inputline Token 100 50 A "proxy is defined as a recognizable collection of LOC. Objects are typical proxies in an object-oriented systems subprograms are typical proxies in traditional functionally-decomposed systems. If you are using a functionally-decomposed (meaning, non-OO) approach, the number of methods for each proxy will be *1. If you are using an O0 approach, the number of methods will be a count of the methods associated with an object or "1" for stand-alone subprogams Ploase provide an oxplanation if the "Total LOC" count is not oqual to tho sum of the Proxy LOC. Test your program using the source code from Assignments 1, 2, and 3. This homework assignment is be accomplished individually Please note that future homework assignments may require the use of your LOC counter Be honest in your data. Your grade depends on how you follow the process, not on the speed of your work or the number of defects found
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
