REPUBLIC OF THE PHILIPPINES
LAGUNA STATE POLYTECHNIC UNIVERSITY
SINILOAN HOST CAMPUS
SINILOAN LAGUNA
SUBMITTED BY :
SOFIA D. PALAWAN
KARA CRYSTAL R. PASCASIO
SUBMITTED TO :
MS AILEEN MAGTIBAY
AIT 2-1
ANALYSIS FOR MATRIX ADDITION
PROGRAMMING
is the art of making a computer do what you want it to do.
At the very simplest level it consists of issuing a sequence of commands to a computer to
achieve an objective.
A vocabulary and set of grammatical rules for instructing a computer to perform specific
tasks. The term programming language usually refers to high-level languages, such as
BASIC, C, C++, COBOL, FORTRAN, Ada, and Pascal. Each language has a unique set
of keywords (words that it understands) and a special syntax for organizing program
instructions. Computer Programming
PURPOSE OF PROGRAMMING FOR MATRIX
Their purpose is to police the system and terminate any entity that may threaten the
stability or function of the Matrix, such as Red pills and Exiled programs.
EXPLANATION FOR MATRIX ADDITION
In matrix addition, these programs you should notice the branch construction which
follows the size statements. This is included as an error message.
In the case of add, an error is made if we attempt to add matrices of different sizes.
The words surrounded by the quotes will be treated as text and sent to the screen as the
value of the variable. Following the message is the command return, which is the
directive to send the control back to the function which called add or return to the
prompt. I usually only recommend using the return command in the context of an error
message.
#include<iostream>
using namespace std;
int main()
{
int i,j,m1,m2,n1,n2;
int a[10][10], b[10][10], c[10]
[10];
cout<<"Enter row of matrix A:
";
cin>>m1;
cout<<"Enter column of matrix
A: ";
cin>>n1;
cout<<"Enter row of matrix B:
";
cin>>m2;
cout<<"Enter column of matrix
B: ";
cin>>n2;
if (m1!=m2 && n1!=n2)
{
cout<<"Both the matrices
should be of same order";
}
else{
cout<<"Enter elements of
matrix A["<<m1<<"]
["<<n1<<"]"<<endl;
for (i=0 ; i<m1 ; i++)
{
for (j=0 ; j<n1 ; j++)
cin>>a[i][j];
}
cout<<"Enter elements
of matrix B["<<m2<<"]
["<<n2<<"]"<<endl;
for (i=0 ; i<m2 ; i++)
{
for (j=0 ; j<n2 ; j++)
cin>>b[i][j];
}
for (i=0 ; i<m1 ; i++)
{
for (j=0 ; j<n2 ; j++)
c[i][j]=a[i][j]+b[i][j];
}
cout<<"Addition of matrices A
and B";
for(i=0 ; i<m1 ; i++)
{
cout<<endl;
for(j=0 ; j<n2 ; j++)
cout<<c[i][j]<<" ";
}}
cout<<endl;
system("pause");
return 0;
}
OUTPUT OF MATRIX ADDITION
Matrix print
Matrix print

More Related Content

PDF
E7
PPTX
A Crash Course in C Part-1
DOCX
C language function
PDF
Functional programming
PPT
Function-Definition, Need, Declaration, Definition, Arguments, Return Value
PPTX
Multi layered perceptron (mlp)
PPT
Basic structure of C++ program
PDF
Python Programming - Introduction
E7
A Crash Course in C Part-1
C language function
Functional programming
Function-Definition, Need, Declaration, Definition, Arguments, Return Value
Multi layered perceptron (mlp)
Basic structure of C++ program
Python Programming - Introduction

What's hot (8)

PPT
Analytical Models of Parallel Programs
PPT
Dynamic programming 2
PDF
Pooja Sharma , BCA Third Year
PDF
Divide&Conquer & Dynamic Programming
PPTX
TechDaysNL 2015 - F# for C# Developers
PPTX
C programming presentation(final)
DOC
Ocs752 unit 4
PDF
Main topic 3 problem solving and office automation
Analytical Models of Parallel Programs
Dynamic programming 2
Pooja Sharma , BCA Third Year
Divide&Conquer & Dynamic Programming
TechDaysNL 2015 - F# for C# Developers
C programming presentation(final)
Ocs752 unit 4
Main topic 3 problem solving and office automation
Ad

Viewers also liked (20)

PPTX
Benny Salaets - Realising the Digital Agend in Flanders
PDF
Beijing MoST standards + IPR conference Clark-OASIS-2011
PDF
Oracle Financial Services - Latest Offerings Brief - Vietnam Cust Appreciatio...
PDF
Ict Sd09 Overal In Je Leven Kom Je 1700 Tegen
PPS
Ferias Em Africa 2
PPT
Leen Vandezande - slimme energie diensten
PPT
Why drivers stay with fleets
PPT
Symptoms of a Billings and Payment Problem
PDF
Romas04 User Driven Living Lab Innovation For Mobile City Applications Jo Pi...
DOC
A S S I N G M E N T
PDF
Medición de la transferencia universitaria según los ranking internacionales
PDF
Q932+sgo reference fa lec
ODP
Lucía folclore-galego
PDF
33720055
ODP
Lucía folclore-inglés
PDF
Wim De Waele - IBBT Strategy
PDF
Workshopvin6 User Interface Adaptation
PDF
Acknowledge 06 Competentiemanagement In Het Acknowledge Platform Luk Vervenne...
PDF
Im3 06 Telemonitoring, Uitdagingen Voor De Gezondheidszorg Jo De Cock
Benny Salaets - Realising the Digital Agend in Flanders
Beijing MoST standards + IPR conference Clark-OASIS-2011
Oracle Financial Services - Latest Offerings Brief - Vietnam Cust Appreciatio...
Ict Sd09 Overal In Je Leven Kom Je 1700 Tegen
Ferias Em Africa 2
Leen Vandezande - slimme energie diensten
Why drivers stay with fleets
Symptoms of a Billings and Payment Problem
Romas04 User Driven Living Lab Innovation For Mobile City Applications Jo Pi...
A S S I N G M E N T
Medición de la transferencia universitaria según los ranking internacionales
Q932+sgo reference fa lec
Lucía folclore-galego
33720055
Lucía folclore-inglés
Wim De Waele - IBBT Strategy
Workshopvin6 User Interface Adaptation
Acknowledge 06 Competentiemanagement In Het Acknowledge Platform Luk Vervenne...
Im3 06 Telemonitoring, Uitdagingen Voor De Gezondheidszorg Jo De Cock
Ad

Similar to Matrix print (20)

PPTX
Introduction to c
PDF
1588147798Begining_ABUAD1.pdf
PPTX
C Language ppt create by Anand & Sager.pptx
PPTX
Introduction to C Unit 1
PDF
Automatic Task-based Code Generation for High Performance DSEL
PPTX
C_Progragramming_language_Tutorial_ppt_f.pptx
PDF
C sharp chap6
ODP
Introduction to MPI
PPTX
IIM.Com-FIT-Unit2(14.9.2021 TO 30.9.2021).pptx
PDF
A tutorial on C++ Programming
PPTX
C programming language tutorial
DOCX
COMP 2103X1 Assignment 2Due Thursday, January 26 by 700 PM.docx
PPTX
Dr Mrs A A Miraje C Programming PPT.pptx
PDF
C programming
PPTX
cmp104 lec 8
PDF
(ThoughtWorks Away Day 2009) one or two things you may not know about typesys...
PDF
Class 12 computer sample paper with answers
PPTX
Getting started in c++
PPTX
C Programming Language Tutorial for beginners - JavaTpoint
PPTX
C++ Unit 1PPT which contains the Introduction and basic o C++ with OOOps conc...
Introduction to c
1588147798Begining_ABUAD1.pdf
C Language ppt create by Anand & Sager.pptx
Introduction to C Unit 1
Automatic Task-based Code Generation for High Performance DSEL
C_Progragramming_language_Tutorial_ppt_f.pptx
C sharp chap6
Introduction to MPI
IIM.Com-FIT-Unit2(14.9.2021 TO 30.9.2021).pptx
A tutorial on C++ Programming
C programming language tutorial
COMP 2103X1 Assignment 2Due Thursday, January 26 by 700 PM.docx
Dr Mrs A A Miraje C Programming PPT.pptx
C programming
cmp104 lec 8
(ThoughtWorks Away Day 2009) one or two things you may not know about typesys...
Class 12 computer sample paper with answers
Getting started in c++
C Programming Language Tutorial for beginners - JavaTpoint
C++ Unit 1PPT which contains the Introduction and basic o C++ with OOOps conc...

More from Sofia Palawan (8)

DOC
Itnarrativereportformat
DOC
Magtibay buk bind#2
DOC
DOCX
DOC
Resume kara crystal pascasio
DOC
Resume sofia p.
DOC
Buwang wika
PPT
GROUP5-SYLLABLES
Itnarrativereportformat
Magtibay buk bind#2
Resume kara crystal pascasio
Resume sofia p.
Buwang wika
GROUP5-SYLLABLES

Recently uploaded (20)

PDF
NewMind AI Weekly Chronicles – August ’25 Week III
PDF
A contest of sentiment analysis: k-nearest neighbor versus neural network
PDF
ENT215_Completing-a-large-scale-migration-and-modernization-with-AWS.pdf
PPTX
Modernising the Digital Integration Hub
PDF
UiPath Agentic Automation session 1: RPA to Agents
PDF
Enhancing plagiarism detection using data pre-processing and machine learning...
PPTX
2018-HIPAA-Renewal-Training for executives
PDF
Taming the Chaos: How to Turn Unstructured Data into Decisions
PDF
Convolutional neural network based encoder-decoder for efficient real-time ob...
PDF
1 - Historical Antecedents, Social Consideration.pdf
PDF
Comparative analysis of machine learning models for fake news detection in so...
PPTX
The various Industrial Revolutions .pptx
PDF
Flame analysis and combustion estimation using large language and vision assi...
PDF
How IoT Sensor Integration in 2025 is Transforming Industries Worldwide
PDF
sbt 2.0: go big (Scala Days 2025 edition)
PPTX
Build Your First AI Agent with UiPath.pptx
PPTX
Custom Battery Pack Design Considerations for Performance and Safety
PDF
Consumable AI The What, Why & How for Small Teams.pdf
PDF
“A New Era of 3D Sensing: Transforming Industries and Creating Opportunities,...
PPTX
Final SEM Unit 1 for mit wpu at pune .pptx
NewMind AI Weekly Chronicles – August ’25 Week III
A contest of sentiment analysis: k-nearest neighbor versus neural network
ENT215_Completing-a-large-scale-migration-and-modernization-with-AWS.pdf
Modernising the Digital Integration Hub
UiPath Agentic Automation session 1: RPA to Agents
Enhancing plagiarism detection using data pre-processing and machine learning...
2018-HIPAA-Renewal-Training for executives
Taming the Chaos: How to Turn Unstructured Data into Decisions
Convolutional neural network based encoder-decoder for efficient real-time ob...
1 - Historical Antecedents, Social Consideration.pdf
Comparative analysis of machine learning models for fake news detection in so...
The various Industrial Revolutions .pptx
Flame analysis and combustion estimation using large language and vision assi...
How IoT Sensor Integration in 2025 is Transforming Industries Worldwide
sbt 2.0: go big (Scala Days 2025 edition)
Build Your First AI Agent with UiPath.pptx
Custom Battery Pack Design Considerations for Performance and Safety
Consumable AI The What, Why & How for Small Teams.pdf
“A New Era of 3D Sensing: Transforming Industries and Creating Opportunities,...
Final SEM Unit 1 for mit wpu at pune .pptx

Matrix print

  • 1. REPUBLIC OF THE PHILIPPINES LAGUNA STATE POLYTECHNIC UNIVERSITY SINILOAN HOST CAMPUS SINILOAN LAGUNA SUBMITTED BY : SOFIA D. PALAWAN KARA CRYSTAL R. PASCASIO SUBMITTED TO : MS AILEEN MAGTIBAY AIT 2-1
  • 2. ANALYSIS FOR MATRIX ADDITION PROGRAMMING is the art of making a computer do what you want it to do. At the very simplest level it consists of issuing a sequence of commands to a computer to achieve an objective. A vocabulary and set of grammatical rules for instructing a computer to perform specific tasks. The term programming language usually refers to high-level languages, such as BASIC, C, C++, COBOL, FORTRAN, Ada, and Pascal. Each language has a unique set of keywords (words that it understands) and a special syntax for organizing program instructions. Computer Programming PURPOSE OF PROGRAMMING FOR MATRIX Their purpose is to police the system and terminate any entity that may threaten the stability or function of the Matrix, such as Red pills and Exiled programs. EXPLANATION FOR MATRIX ADDITION In matrix addition, these programs you should notice the branch construction which follows the size statements. This is included as an error message. In the case of add, an error is made if we attempt to add matrices of different sizes. The words surrounded by the quotes will be treated as text and sent to the screen as the value of the variable. Following the message is the command return, which is the directive to send the control back to the function which called add or return to the prompt. I usually only recommend using the return command in the context of an error message.
  • 3. #include<iostream> using namespace std; int main() { int i,j,m1,m2,n1,n2; int a[10][10], b[10][10], c[10] [10]; cout<<"Enter row of matrix A: "; cin>>m1; cout<<"Enter column of matrix A: "; cin>>n1; cout<<"Enter row of matrix B: "; cin>>m2; cout<<"Enter column of matrix B: "; cin>>n2; if (m1!=m2 && n1!=n2) { cout<<"Both the matrices should be of same order"; } else{ cout<<"Enter elements of matrix A["<<m1<<"] ["<<n1<<"]"<<endl; for (i=0 ; i<m1 ; i++) { for (j=0 ; j<n1 ; j++) cin>>a[i][j]; } cout<<"Enter elements of matrix B["<<m2<<"] ["<<n2<<"]"<<endl; for (i=0 ; i<m2 ; i++) { for (j=0 ; j<n2 ; j++) cin>>b[i][j]; } for (i=0 ; i<m1 ; i++) { for (j=0 ; j<n2 ; j++) c[i][j]=a[i][j]+b[i][j]; } cout<<"Addition of matrices A and B"; for(i=0 ; i<m1 ; i++) { cout<<endl; for(j=0 ; j<n2 ; j++) cout<<c[i][j]<<" "; }} cout<<endl; system("pause"); return 0; } OUTPUT OF MATRIX ADDITION