Advertisement
Guest User

Untitled

a guest
Mar 22nd, 2019
138
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.38 KB | None | 0 0
  1. #include <stdio.h>
  2.  
  3. int main(void){
  4.     FILE* input = fopen("test.txt", "r");
  5.     if (input == NULL){
  6.         printf("Error opening input file. Exiting program\n");
  7.         return -1;
  8.     }
  9.    
  10.     int rasa = 0;      
  11.     char *lastAndFirst = "hello";
  12.     printf("\nHere1\n");
  13.     fscanf(input, "%s", lastAndFirst); //last andFirst is sometshing like [marry,Jane'0']
  14.    
  15.  
  16.     // Close the input file
  17.     fclose(input);
  18.        
  19. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement