Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <iosteam>
- #include <stdlib.h>
- #include <string.h>
- //leggi file
- //3 comandi shell
- void leggi_file(int * num_rot; int * num_righe; int * matrix){
- char * command = malloc(sizeof(char)*50);
- strcpy(command, "head -n 1 test.txt")
- &num_rot =(int)system(command);
- strcpy(command, "head -n 2 test.txt")
- &num_rot =(int)system(command);
- printf("num rot: %d", &num_rot);
- }
- //ruota - rotazioni modulo 4
- //output
- int main() {
- int * num_rot;
- int * num_righe;
- int * matrix;
- leggi_file(num_rot, num_righe, matrix);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement