Ok nevermind. I got it.
Link lists makes my head hurts. Thnks anyways.
Type: Posts; User: andone
Ok nevermind. I got it.
Link lists makes my head hurts. Thnks anyways.
This is what i have so far. I need to write a function to add and remove a field from a file. I called the add function in main but do not know what to do next.
#include <stdio.h>
#include...
Ok i got it to work, but not quite correct. It reads every character instead of every floating number. It also doesn't read the last line.
int columns (int input)
{
FILE* spData;
FILE*...
Thx Vart. I'm not asking for final answers, just something to base on. I want to learn this stuff :)
I'll give it a try.
*sigh*... now i'm hella lost.
fgets and sscanf are in the chapter labled "string" in my book. Not only that, that is 4 chapters away from what we are studying right now. The functions we are...
Ok, been working on this for a few days now... Just to find out that I can't use string functions, only basic read/write from files. Please dont send me running around in circles and give me some...
sorry i wasn't more clear, a column in this case contains floating numbers, separated by about 6 spaces. Thanks for quick reply.
edit: also, each line has a different amount of columns.
I need to read the total amount of columns per line from a file. I have absolutely no clue what to put in the loop. Any help is welcome. Thanks.
void numofcol (int input)
{
FILE* spData;...
Thanks guys. It lives!
is there any other way? Because we haven't learned arrays yet.
I need to find the sum of all numbers in a file. I read in the file, but how do i save all the numbers and then add them? Thanks guy/gals.
void sumofnum (int input)
{
FILE* spData;
int...
nevermind. I figured it out. thx anywayz
Ok there are seven fuctions. This program calculates the different between two time intervals. The fuction "getTime" has to be called twice by main, once to get the start time, and then again to get...