Question: Needed in c programming language Question 3 [ 6 marks ] In this question you are going to make use of your answer for Question

Needed in c programming language
Question 3[6 marks]
In this question you are going to make use of your answer for Question 2 to create a working program (so
Create a program that reads all the superhero information from the provided superheros.txt file and prints
the information to the screen. Your program must meet these requirements:
Include the header file from Question 2 and use the functions defined there (createSuperhero
and clearSuperhero) to complete this question. Do not redefine those functions.
Use a dynamic array of Superhero struct pointers to store the superhero information. This is the
recommended approach (instead of a static array with a fixed size) as we might change the
number of entries in the provided file, and dynamic arrays can accommodate that variation.
There must be no memory leaks (e.g., your program requests some memory but does not release
them all before it terminates). We will use a tool called valgrind to test the program compiled
from your code which reports if there is any memory leaks (refer to Canvas for details).
Start with a fancy banner. There is no specific requirement besides it must include your name, 9-
digit SFU ID, and your SFU email address. Let your creativity shine, just nothing offensive.
Print all the entries from the first to the last, along with a Superhero #. Do not reorder the entries*.
Needed in c programming language Question 3 [ 6

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!