#include <stdio.h>
int main(){
char *names[1024];
float *rates[20];
FILE* file;
file = fopen("tecaji.txt","r");
while(!feof(file)){
fscanf(file, "%s", &names);
for(int i = 0; i < 20; i++){
fscanf(file, "%f", &rates);
}
}
for(int a = 0; a < 50; a++){
printf("%s", names[a]);
}
}
The file contents look like this: String Float Float Float ... 20 Float's after
each string.
March 3.56 24.3 2.5 67.4....
April 4.53 5.3 46....
Anyways i am reading the file no problems there and i want to add strings to names
table and numbers to rates table simple.. For now i wish to use two tables instead
of a two dimensional table.
But i have a problem i am writing in Pelles C keeps giving me error that
it's expecting char * but finding char **