C_ass59

  • Uploaded by: Surya Tej
  • 0
  • 0
  • May 2020
  • PDF

This document was uploaded by user and they confirmed that they have the permission to share it. If you are author or own the copyright of this book, please report to us by using this DMCA report form. Report DMCA


Overview

Download & View C_ass59 as PDF for free.

More details

  • Words: 303
  • Pages: 2
/* Write a C program to accept a matrix of given order and * interchnge any two rows and columns in the original matrix*/ #include <stdio.h> void main() { static int m1[10][10],m2[10][10]; int i,j,m,n,a,b,c, p, q, r; printf ("Enter the order of the matrix\n"); scanf ("%d %d",&m,&n); printf ("Enter the co-efficents of the matrix\n"); for (i=0; i<m;++i) { for (j=0;j
/* first row has index is 0 */

printf ("Enter the numbers of two columns to be exchnged\n"); scanf ("%d %d",&p,&q); printf ("The given matrix is \n"); for (i=0;i<m;++i) { for (j=0;j
/* first column index is 0 */

printf ("The matix after interchnging the two rows(in the original matrix)\n"); for (i=0; i<m; ++i) { for (j=0; j
} }

printf ("\n");

printf("The matix after interchnging the two columns(in the original matrix)\n"); for (i=0;i<m;++i) { for (j=0;j

More Documents from "Surya Tej"

C_ass59
May 2020 7
Unit Iii
May 2020 9
C_ass50
May 2020 7
Fibbonacci Series
May 2020 3
Unit I
May 2020 10