Advertisement
Josif_tepe

Untitled

Jan 18th, 2024
417
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.36 KB | None | 0 0
  1. #include <stdio.h>
  2. #include <ctype.h>
  3. #include <string.h>
  4.  
  5. int main() {
  6.    FILE * in = fopen("input.txt", "r");
  7.     FILE * out = fopen("output.txt", "w");
  8.  
  9.    if(in == NULL) {
  10.        printf("Fajlot ne postoi\n");
  11.        return 0;
  12.    }
  13.     char s[1000];
  14.     while(fgets(s, 500, in) != NULL) {
  15.         fprintf(out, "%s", s);
  16.     }
  17.     return 0;
  18. }
  19.  
  20.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement