Loops - English
- subtitles off
- captions off
- English
- Questions posted on Forums
- C and Cpp Tutorials - English
-
Matrix
#include <stdio.h>int main(){ int rowCount, columnCount, i, j; int firstMatrix[10][10], secondMatrix[10][10], resultMatrix[10][10]; printf("Number of rows of matrices to be subtracted : "); scanf("%d", &rowCount); printf("Number of columns matrices to be subtracted : "); scanf("%d", &columnCount); printf("Elements of first matrix : \n"); for (i = 0; i < rowCount; i++) for (j = 0; j < columnCount; j++) scanf("%d", &firstMatrix[i][j]); printf("Elements of second matrix : \n"); for (i = 0; i < rowCount; i++) for (j = 0; j < columnCount; j++) scanf("%d", &secondMatrix[i][j]); printf("Difference of entered matrices : \n"); for (i = 0; i < rowCount; i++) { for (j = 0; j < columnCount; j++) { resultMatrix[i][j] = firstMatrix[i][j] - secondMatrix[i][j]; printf("%d\t",resultMatrix[i][j]); } printf("\n"); } return 0;}ByN.L.PoojaEce departmentIRTT
04-05M 50-60S Poojanl
Answer last updated on: Aug. 19, 2024, 3:49 p.m.
-
Loops
Explain about for loop??
01-02M 10-20S Prasanna123
Answer last updated on: April 13, 2017, 9:05 a.m.
-
1First C Program
-
2First Cpp Program
-
3Tokens
-
4Functions
-
5Scope Of Variables
-
6If And Else If statement
-
7Nested If And Switch Statement
-
8Increment And Decrement Operators
-
9Arithmetic Operators
-
10Relational Operators
-
11Logical Operators
-
Loops
-
13Arrays
-
14Working With 2D Arrays
-
15Strings
-
16String Library Functions
-
17Working With Structures
-
18Understanding Pointers
-
19Function Call
-
20File Handling In C
Questions posted on ST Forums:
29093 visits
Outline:
Loops -Loops -Syntax for while and do-while loop -Comparison of while and do-while loop -Syntax for -for loop -Errors
Width: | 800 | Height: | 640 |
---|---|---|---|
Duration: | 00:11:11 | Size: | 6.5 MB |
Show video info