Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- FILE* file = fopen("decode.txt", "r");
- 20 char line[128];
- 21
- 22 int count = 0;
- 23 int index = 0;
- 24 while(fgets(line, sizeof(line), file) != NULL)
- 25 {
- 26 if(count == 0)
- 27 {
- 28 count = atoi(line);
- 29 printf("%d\n",count);
- 30 }
- 31 else if(count != 0)
- 32 {
- 33 if(index < count)
- 34 {
- 35 //printf(line);
- 36
- 37 char character[2];
- 38 char* line2 = "hello";
- 39 strncpy(character,line, 1);
- 40 character[1] = "\0";
- 41 //printf(blah);
- 42 printf("\n");
- 43 printf(character);
- 44 printf("%d",strlen(character));
- 45 printf("\n");
- 46 //int len = strlen("jello");
- 47 //printf("%d",len);
- 48 //char* code;
- 49 //strncpy(code, line+1, strlen(line)-1);
Add Comment
Please, Sign In to add comment