Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <string.h>
- #include <stdlib.h>
- #include "realezat.h"
- int main (void)
- {
- int i;
- FILE *out;
- int *stu;
- char *cru;
- out=fopen("output.txt", "w+");
- stu=(int*)malloc(sizeof(int)*1);
- stu[0]=0;
- cru=(char*)malloc(sizeof(char)*1);
- if(reshift("input.txt", 1, cru, stu)!=0)
- {
- for(i=0; i<stu[0]; i++)
- {
- fprintf(out, "%c", cru[i]);
- }
- free(cru);
- free(stu);
- fclose(out);
- return 0;
- }
- fclose(out);
- free(cru);
- free(stu);
- return -1;
- }
- ~
Advertisement
Add Comment
Please, Sign In to add comment