Menu
Question Index
...

Write a program to find if the given matrix is a lower triangle matrix.
Assume that matrixes are square matrices.

Input (Two Dimensional matrix) Output (boolean)
5   0   0
4   3   0
5   2   8
true
6   0   0   0
-3   4   0   0
1   9   7   0
5   2   3   8
true
0  0
0  0
true
0   9   8
8   0   0
6  -4   0
false
12   89   77
0   99   66
45   0   111
false



class IsLowerTriangleMatrix
{
    public static void main(String s[])
    {
        int input[][] = {{5, 0, 0}, {4, 3, 0}, {5, 2, 8}};
        System.out.println("The given matrix is lower triangle matrix : " + isLowerTriangleMatrix(input));

    }


    public static boolean isLowerTriangleMatrix(int matrix[][]) {
    }

}

Doubts

Problems

Topic: Learn Arrays And Loops

Read this topic
Take test on this topic

0
Wrong
Score more than 2 points

© meritcampus 2019

All Rights Reserved.

Open In App