Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <conio.h>
- #define N 3
- void main()
- {
- int A[N][N],X[N],i,j;
- FILE *fp;
- fp=fopen("C:\\Data\\data.txt", "r");
- for (i=0;i<N;i++)
- {
- for (j=0;j<N;j++)
- fscanf (fp,"%d ",&A[i][j]);
- }
- for (i=0;i<=N-1;i++)
- {
- for (j=0;j<=N-1;j++)
- printf ("%5d", A[i][j]);
- printf ("\n");
- }
- fclose(fp);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement