counting number of lines in my output file
hey guys,
im trying to use malloc and realloc in my programme, as the sizes of my arrays change with some parameters in my program.But to use them i need to calculate the number of lines that I will have in my output file in the end, so that i can allocate the right amount of memory.But how could i go about writing the code for calculating the number of lines.
in my output file, the first line lists some constants..so thats line number 1..then underneath i have two colums of time against x(t) which are both arrays..
Merry Christmass!!
xx