Traitement-signal-plantes/C-Script/getArray.c

42 lines
723 B
C
Raw Normal View History

2022-05-05 16:40:03 +02:00
#include "b2hd.h"
typedef struct values
{
int allValues[1000][8];
}values;
values getArray(){
values tab;
char *token;
2022-05-30 12:54:56 +02:00
char buffer[200];
char *pbuff;
int value;
2022-05-05 16:40:03 +02:00
2022-05-30 12:54:56 +02:00
/*fscanf(stdin, "%s", buff);
printf(buff);
2022-05-05 16:40:03 +02:00
token = strtok(buff , ",");
2022-05-30 12:54:56 +02:00
printf(token);
2022-05-05 16:40:03 +02:00
int i = 0 ;
2022-05-30 12:54:56 +02:00
int j = 0 ;*/
int i = 0;
while(1){
if (!fgets(buffer, sizeof buffer, stdin)) break;
printf("Line contains : %s", buffer);
pbuff = buffer;
/*hile (1) {
if (*pbuff == '\n') break;
value = strtol(pbuff, &pbuff, 10);
//printf("%d", value);
2022-05-05 16:40:03 +02:00
}
2022-05-30 12:54:56 +02:00
printf("\n");*/
2022-05-05 16:40:03 +02:00
}
2022-05-30 12:54:56 +02:00
}
int main(int argc , char** argv){
getArray();
}