anyone?
Type: Posts; User: ss7
anyone?
hm ok, I just replaced the read function with the code above and it gave me errors:
c:19: warning: `return' with a value, in function returning void
c:54: warning: passing arg 2 of `read' makes...
ok this is what I changed it to:
void read(double a[N][N], int n, FILE* inp)
{
int i,j;
fscanf(inp,"%d", &n);
for (i=0; i<n; i++)
{
my question now, is for example lets say I have input file with 3 matrices of sizes 2x2, 3x3 and 4x4. How can I input all 3 matrices at the same time from 1 file? I tried putting while loop in read...
thank you, thank you, thank you, I got it..finally........ (and it was supposed to be easy part of an assignment!).
Figuring out determinants is for tomorrow.
hey thanks a lot for your help vart!
I think it kinda worked, it prints out the numbers, but I thought it would print it out in the form of matrix, is anything Im missing?
here is the result...
1. ok put back the ampersand
2. replaced scanf with fscanf in read function
3. how would the pointer work exactly? Something like this?
void read(double a[N][N], int n)
{
int i,j, x;...
hey thanks for pointing that out, I got rid of that, and it still has that error while running:(
I got it to compile without any errors using this code:
#include<stdio.h>
#include<stdlib.h>
#define N 10
#define NMAX 4
void read(double a[N][N], int n)
thanks for the reply, I just updated the reworked program and errors, still getting those few.
Hi guys, I have to make a program to print out the matrix from the file and its determinant. Here's the outline Im supposed to fill out:
#include
#define N 10
#define NMAX 4
double...