Question: Programming Challenge # 3 : Create a C + + program with two functions: main ( ) and DoYourJob ( ) . The program must
Programming Challenge #:
Create a C program with two functions: main and DoYourJob The program must read data from a text file containing coordinates of points on the plane. The data must be in matrix format with two columns and an beforehand unknown number of rows. Each row of data represents a point, where the first number is the coordinate and the second is the coordinate. The program must read this data and display a polygonal curve on the graphics screen. The curve must connect the points successively, making them the vertices of the polygonal curve.
Demonstrate the functionality of the program with two example data sets:
A file whose data defines a Maltese cross.
A file whose data defines an isosceles triangle.
Show the output to your instructor to check the performance of the program. Explain how you divide the functionality of the program between two functions. This means explaining what the DoYourJob function and the main function do in your program?
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
