MATRIX MULTIPLICATION FOR ANY ORDER

Simply u'll love it.......


# include

int row ,column;
void setmatrixA(x,y){
int row ,column;
int matrixA[x][y];
printf("Enter The Values for matrixA : \n");
for(row=0; row< column="0;column<">

printf("\n");
}
void setmatrixB(x,y){
int matrixB[x][y];
printf("Enter The Values for matrixB : \n");
for(row=0;row< column="0;column<">
printf("\n");
}

void multiplication(x,y,z){

int matrixA[x][z],matrixB[z][y];
int AB[x][y];
int i,mul,value;
int row ,column;
for(row=0;row< column= "0;column< " value="0;" i="0;i<" mul="matrixA[row][i]*matrixB[i][row];">

double display(x,y){
int AB[x][y];
printf("Multiplied Matrix Of Order %d * %d \n", x,y);
printf("============================== \n");
for(row=0;row<>
printf("\t\t");
for(column=0;column<>
printf(" %d ", AB[row][column]);
}
printf("\n");
}
}

int main(){

printf("\t\t--------------------------------------------- \n");
printf("\t\t Matrix Multiplication To Any Order \n");
printf("\t\t--------------------------------------------- \n\n\n");

printf("\t\t--------------------------------------------- \n\n\n");
printf("\t\t-----------------INSTRUCTIONS---------------- \n\n\n");
printf("This is a interface based multiplicater so please enter your data as you\n");
printf("normally enter at your note book\n");
printf("Example: Matrix Of 3*2 Is as follows \n");
printf("\t\t a b \n");
printf("\t\t c d \n");
printf("\t\t e f \n");
printf("You Should Strictly Follow this orders to maintain the system runs beautifully!!!! \n");



int a1,a2,b1,b2;

printf("Enter The Order for matrixA : \n");

scanf("%d %d", &a1,&a2);
printf("Enter The Order for matrixB : \n");
scanf("%d %d", &b1,&b2);
if(a2==b1){
setmatrixA(a1,a2);
setmatrixB(b1,b2);
multiplication(a1,b2,a2);
display(a1,b2);
}else{
printf("Your Input Is Invalid \n");
printf("Please Enter The New Values \n");


}
return 0;
}