2. Practice with arrays and file I/O. Write a program that will read in the complex values stored in the
file impedance.txt that we used in class, writing a new file which contains the magnitude and angle
corresponding to each complex value.
Now, although you do not NEED to use arrays to do this (you could read in one value, then write its
magnitude and angle before going to the next value) I want you to get some practice with arrays!
Might as well practice structures too.
So... read the data into an array of complex values. Define a new struct that would hold a magnitude
and an angle. Create an array of that new struct type, and write a loop to fill it with the magnitudes
and angles from the original data array. Finally, write all those magnitudes and angles into a file, and
print that file as your results.