Questions

Q:

Write a program for matrix multiplication in c

Answer

#include <stdio.h>


int main() {


  int a[5][5], b[5][5], c[5][5], i, j, k, sum = 0, m, n, o, p;


  printf( "\nEnter the row and column of first matrix" );


  scanf( "%d %d", &m, &n );


  printf( "\nEnter the row and column of second matrix" );


  scanf( "%d %d", &o, &p );


  if(n!=o) {


      printf( "Matrix mutiplication is not possible" );


      printf( "\nColumn of first matrix must be same as row of second matrix" );


  }


  else {


      printf( "\nEnter the First matrix" );


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


      for( j=0; j<n; j++ )


           scanf( "%d", &a[i][j] );


      printf( "\nEnter the Second matrix" );


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


      for( j=0; j<p; j++ )


           scanf( "%d", &b[i][j] );


      printf( "\nThe First matrix is\n" );


      for( i=0; i<m; i++ ) {


      printf("\n");


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


           printf( "%d\t", a[i][j] );


      }


      }


      printf( "\nThe Second matrix is\n" );


      for( i=0; i<o; i++ ) {


      printf("\n");


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


           printf( "%d\t", b[i][j] );


      }       


      }


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


      for( j=0; j<p;j++ )


           c[i][j] = 0;


      for( i=0; i<m; i++ ) { //row of first matrix


      for( j=0; j<p; j++ )  {  //column of second matrix


           sum = 0;


           for( k=0; k<n; k++ )


               sum = sum + a[i][k]*b[k][j];


           c[i][j] = sum;


      }


      }


  }


  printf( "\nThe multiplication of two matrix is\n" );


  for( i=0; i<m; i++ ) {


      printf("\n");


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


           printf( "%d\t", c[i][j] );


      }


  }


  return 0;


}

Report Error

View answer Workspace Report Error Discuss

Subject: Programming

0 2354
Q:

India’s who has won the girl's title in the IBSF World Under-16 Snooker Championships 2018?

A) Keerthana Pandian B) Sangeeta Chanu
C) Kumar Mangalan D) Thangjam Tababi Devi
 
Answer & Explanation Answer: A) Keerthana Pandian

Explanation:

India's Keerthana Pandian has won the girls’ title in the IBSF World Under-16 Snooker Championships.

 

In the final in St Petersburg, Russia, Keerthana outclassed her Belarussian rival Albina Leschuk 3-1.

Report Error

View Answer Report Error Discuss

Filed Under: Sports
Exam Prep: AIEEE , Bank Exams , CAT
Job Role: Analyst , Bank Clerk , Bank PO

2 2354
Q:

Farming in the early New England colonies was challenging because

A) unfamiliar weather and soil conditions affected cultivation B) English laws restricted which crops farmers could plant
C) English investors promoted manufacturing over farming D) foreign plants soon grew out of control in the American soil
 
Answer & Explanation Answer: A) unfamiliar weather and soil conditions affected cultivation

Explanation:

Farming in the early New England colonies was challenging because unfamiliar weather and soil conditions affected cultivation.

Report Error

View Answer Report Error Discuss

Filed Under: World History
Exam Prep: AIEEE , Bank Exams , CAT
Job Role: Analyst , Bank Clerk , Bank PO

2 2354
Q:

Read the passage carefully and choose the best answer to each question out of the four alternatives and click the button corresponding to it.

The Alaska pipeline starts at the frozen edge of the Arctic Ocean. It stretches southward across the largest and northernmost state in the United States, ending at a remote ice-free seaport village nearly 800 miles from where it begins. It is massive in size and extremely complicated to operate. The steel pipe crosses windswept plains and endless miles of delicate tundra that tops the frozen ground. It weaves through crooked canyons, climbs sheer mountains, plunges over rocky crags, makes its way through thick forests, and passes over or under hundreds of rivers and streams. The pipe is 4 feet in diameter, and up to 2 million barrels (or 84 million gallons) of crude oil can be pumped through it daily. Resting on H-shaped steel racks called "bents", long sections of the pipeline follow a zigzag course high above the frozen earth. Other long sections drop out of sight beneath spongy or rocky ground and return to the surface later on. The pattern of the pipeline's up-and-down route is determined by the often harsh demands of the arctic and subarctic climate, the tortuous lay of the land, and the varied compositions of soil, rock, or permafrost (permanently frozen ground). A little more than half of the pipeline is elevated above the ground. The remainder is buried anywhere from 3 to 12 feet, depending largely upon the type of terrain and the properties of the soil. One of the largest in the world, the pipeline cost approximately $8 billion and is by far the biggest and most expensive construction project ever undertaken by private industry. In fact, no single business could raise that much money, so 8 major oil companies formed a consortium in order to share the costs. Each company controlled oil rights to particular shares of land in the oil fields and paid into the pipeline-construction fund according to the size of its holdings. Today, despite enormous problems of climate, supply shortage, equipment breakdowns, labour disagreements, treacherous terrain, a certain amount of mismanagement, and even theft, the Alaska pipeline has been completed and is operating.


What is the capacity of the Alaskan pipeline?

A) 2 million gallons of crude oil B) 4 million barrels of crude oil
C) 84 million gallons of crude oil D) 84 billion barrels of crude oil
 
Answer & Explanation Answer: C) 84 million gallons of crude oil

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: English
Exam Prep: Bank Exams

0 2354
Q:

Read the passage carefully and choose the best answer to each question out of the four alternatives and click the button corresponding to it.


Crude mineral oil comes out of the earth as a thick brown or black liquid with a strong smell. It is a complex mixture of many different substances, each with its own individual qualities. Most of them are combinations of hydrogen and carbon in varying proportions. Such hydrocarbons are also found in other forms such as bitumen, asphalt and natural gas. Mineral oil originates from the carcasses of tiny animals and from plants that live in the sea. Over million of years, these dead creatures form large deposits under sea­bed and ocean currents cover them with a blanket of sand and silt. As this material hardens, it becomes sedimentary rock and effectively shuts out the oxygen, thus preventing the complete decomposition of the marine deposits underneath. The layers of sedimentary rocks become thicker, and heavier. Their pressure produces heat, which transforms the tiny carcasses into crude oil in a process that is still going on today.


The time taken for the marine deposits to harden into rocks is

A) a few centuries B) millions of years
C) a few decades D) thousands of years
 
Answer & Explanation Answer: B) millions of years

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: English
Exam Prep: Bank Exams

0 2353
Q:

Which of the following is not true about tape storage?

A) A benefit of tape is that it allows for nonsequential access. B) A benefit of tape is that it allows for sequential access.
C) Both A & B D) None of the above
 
Answer & Explanation Answer: A) A benefit of tape is that it allows for nonsequential access.

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Computer
Exam Prep: AIEEE , Bank Exams , CAT
Job Role: Analyst , Bank Clerk , Bank PO

2 2353
Q:

Which one of the following is a plant hormone?

A) Cytokinin B) Oestrogen
C) Thyroxin D) Insulin
 
Answer & Explanation Answer: A) Cytokinin

Explanation:

Cytokinins is a Plant hormone which helps in cell division and leads to Growth & formation of shoots, roots & bud.

Report Error

View Answer Report Error Discuss

Filed Under: Biology
Exam Prep: AIEEE , Bank Exams , CAT
Job Role: Analyst , Bank Clerk , Bank PO

1 2353
Q:

Planning Process Group

What are the Project Management Processes included in the Planning Process Group?

Answer



      • Develop Project Management Plan

      • Scope Planning

      • Scope Definition

      • Create WBS

      • Activity Definition

      • Activity Sequencing

      • Activity Resource Estimating

      • Activity Duration Estimating

      • Schedule Development

      • Cost Estimating

      • Cost Budgeting

      • Quality Planning

      • Human Resource Planning

      • Communications Planning

      • Risk Management Planning

      • Risk Identification

      • Qualitative Risk Analysis

      • Quantitative Risk Analysis

      • Risk Response Planning

      • Plan purchases and Acquisitions

      • Plan Contracting



Report Error

View answer Workspace Report Error Discuss

0 2353