Transpose of a matrix in c using dynamic memory allocation


Asked by admin @ in Computer Science viewed by 297 People


C program to find transpose of a matrix using dynamic memory allocation

Answered by admin @



Answer:

Program to Find the Transpose of a Matrix

#include <stdio.h>

int a[10][10], transpose[10][10], r, c, i, j;

printf("Enter rows and columns: ");

scanf("%d %d", &r, &c);

// Assigning elements to the matrix.

printf("\nEnter matrix elements:\n");

for (i = 0; i < r; ++i)

for (j = 0; j < c; ++j) {


Similar Questions

Merits and demerits of static and dynamic memory allocation

Asked by admin @ in Science viewed by 300 persons

Advantages and disadvantages of static and dynamic memory allocation

Difference between static memory allocation and dynamic memory allocation

Asked by admin @ in Computer Science viewed by 252 persons

Differentiate between static and dynamic memory allocation

Which one is used during memory deallocation in c

Asked by admin @ in Computer Science viewed by 341 persons

which one is used during memory deallocation in c? a) remove(p); b) delete(p); c) free(p); d) terminate(p)

The main working memory used by the computer is

Asked by admin @ in Computer Science viewed by 367 persons

The main working memory used by the computer are?

Which of the following is used in main memory

Asked by admin @ in English viewed by 333 persons

Which of the following is used in main memory​

The memory implemented using the semiconductor chips is

Asked by admin @ in Computer Science viewed by 322 persons

1) The memory implemented using the semiconductor chips is​

Is the high speed memory used in the computer

Asked by admin @ in Computer Science viewed by 286 persons

______ is the high speed memory used in the computer. A.RAM B.Hard Disk C.Cache D.BIOS

Cache memory is used in a computer system to

Asked by admin @ in Computer Science viewed by 398 persons

7. Cache memory is used in a computer system to___​

Which of the following occupies more memory in c

Asked by admin @ in Computer Science viewed by 8135 persons

Which data type occupies most amount of memory in c?

What characteristic of read only memory makes it useful

Asked by admin @ in Computer Science viewed by 358 persons

What characteristic of read-only memory (ROM) makes it useful ? (1) ROM information can be easily updated (2) ROM provides very large amounts of inexpensive data storage (3) Data in …

Which memory trick can be used to expand your vocabulary

Asked by maham237 @ in English viewed by 279 persons

I. prefix II. rhyme III. acronym I only I and II II and III I and III

Which of these makes music association a useful memory technique

Asked by maham237 @ in Computers And Technology viewed by 312 persons

Which computer memory is used for storing programs

Asked by maham237 @ in Computers And Technology viewed by 344 persons

RAM Clear sel 19. Which computer memory is used for storing programs and data currently being processed by the CPU? Mass memory RAM O Neo-volatile memory

The parameter passing mechanism used in c is

Asked by admin @ in Computer Science viewed by 350 persons

The parameter passing mechanism used in C is a) call by name b) call by value c) name call d) None of these

The control conditional statements used in c is are

Asked by admin @ in Computer Science viewed by 305 persons

The control/conditional statements used in c is/are

Most viewed questions in Computer Science


A programmer mistakenly writes gor instead of for

Asked by admin @ in Computer Science viewed by 19018 persons


Domestic data entry operator ncert book class 9 solutions

Asked by admin @ in Computer Science viewed by 15805 persons


Information technology code 402 class 9 solutions chapter 1

Asked by admin @ in Computer Science viewed by 10969 persons



Ncert solutions for class 8 computer chapter 1 computer system

Asked by admin @ in Computer Science viewed by 10401 persons


A scrum team works on a 4 weeks sprint

Asked by admin @ in Computer Science viewed by 8721 persons


Which of the following occupies more memory in c

Asked by admin @ in Computer Science viewed by 8135 persons



A database of motor vehicles has the base entity

Asked by admin @ in Computer Science viewed by 7840 persons


The network architecture can be termed as a mcq

Asked by admin @ in Computer Science viewed by 6485 persons


Cat5 and cat6 cabling refer to which reference model layer

Asked by admin @ in Computer Science viewed by 5788 persons



Class 7 computer chapter 3 questions and answers

Asked by admin @ in Computer Science viewed by 5691 persons


Choose the correct options about usability and user experience

Asked by admin @ in Computer Science viewed by 5474 persons


Which advocates daily team meetings for coordination and integration

Asked by admin @ in Computer Science viewed by 4980 persons



Which three security features match the database security level

Asked by admin @ in Computer Science viewed by 4970 persons


Which of the dbms package is not available

Asked by admin @ in Computer Science viewed by 4682 persons


________ aid a business grow and attain its objectives

Asked by admin @ in Computer Science viewed by 4486 persons