Hello,
I've to make a c program with the next specs:

Write a function that is specified as follows:
bool lees_file (char *, int [] [KOLOMMEN_IN]);
The function has as parameters a pointer to a file name and a two dimensional integer array
and a return value of type boolean.
The function opens a file with the specified name and put the contents of that file in a
two-dimensional integer array. The return value is true if the file was opened successfully and false if
This failed.
Also write a program that asks the user to enter a filename. Then open
lees_file function (char *, int [] [KOLOMMEN_IN]) a file with that name. In this case intweek.txt or
intwkd.txt. If a name is entered in a file that does not exist, the program
error message based on the return value of above function.
Next, the function of the contents of that file in a 2-dimensional integer array.
The program consists of only asking for the file name and call the above
function.

Furthermore, the program, the following data:

# Include
# Include <string.h>
# Include <stdlib.h>
typedef enum {false, true} bool;
# Define WEEK_FILE "intweek.txt"
# Define WEEKEND_FILE "intwkd.txt"
# Define RIJEN_IN 12
# Define KOLOMMEN_IN 6
bool lees_file (char *, int [] [KOLOMMEN_IN]);
int main ()
{
cFilename char [50];
int aiData [RIJEN_IN] [KOLOMMEN_IN];
}


Can anyone help me making this program?

best regards,
Floris

We won't write it for you, but help you with what you don't understand. What exactly don't you understand about the assignment? Have you even made an attempt to write the program? What compiler and operating system are you using?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.