jituTechnology

jituTechnology

Program to obtain 3*4 matrix and transpose of it.

/*Q.7.Program to obtain 3*4 matrix and transpose of it.
Programmed by: Jitendra Kr Yadav
Roll : 10116
Date: 2011/04/10*/
#include <stdio.h>
#include <conio.h>
void main()
{
int a[3][4] ={{1,2,3,4},{6,4,7,9},{9,4,2,7}};
int c[4][3];
int i,j;
for(i=0;i<3;i++)
{
     for(j=0;j<4;j++)
           {
           c[j][i] = a[i][j];
         }
          printf (“\n”);
    }
           for(i=0;i<4;i++)
        {
                printf(“\n”);
                for(j=0;j<3;j++)
                printf(“%d\t”,c[i][j]);
        }
                getch();
}

  Result: –

  1            6              9
  2            4              4
  3            7              2
  4            9              7
Add a comment

Comments (1)

  1. Lorinda KoslowApril 5, 2012 Reply
    When someone writes an paragraph he/she keeps the plan of a user in his/her mind that how a user can be aware of it. Thus that’s why this post is outstdanding. Thanks!

Add a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.



Connect with Me

GPO 8973 NPC 541; Kathmandu Nepal
Phone: +977 9851236800

Calendar

April 2024
S M T W T F S
 123456
78910111213
14151617181920
21222324252627
282930