Can you help me with this!!
This is a C program, where the main program is written at the beginning then you have five functions at the bottom, called by the main program. The program creates a file called result.txt once it is run.
I use cygwin for that, you need to locate the file first as if you are using DOS, then type gcc main1.c and press enter followed by ./a then enter to run the program. You’ll get a message saying "file result.txt created!!" then a file will be created in the same folder you saved the program in.
Open the result.txt file you'll be able to know what I want from you.. As you can see all the results are written in one continues line!! Why is that?? I couldn’t figure out what’s wrong or even how can I fix this problem. The results of each function should be printed in different line.
I’m attaching the program and a modified-result.txt file.. I want the file created to look like this one.. can you help!!