Practice Real Company Assessment Patterns • Latest 2025–2026 Mock Tests

Programming Exercises

Write a program to check if a hardcoded 2D array is symmetric along its diagonal.

Medium

Problem Statement

Write a program to check if a hardcoded 2D array is symmetric along its diagonal.

Sample Input

Matrix:
[ [1, 2, 3],
 [2, 4, 5],
 [3, 5, 6] ]

Sample Output

Is Symmetric: True

Limits

Time: 2s · Memory: 256 MB

Code Editor
00:00
using System; class SymmetricMatrix { static void Main() { // Check if the matrix is symmetric along its diagonal } }
Log in or sign up to run or submit your code.Log inSign up
Input
Matrix:
[ [1, 2, 3],
 [2, 4, 5],
 [3, 5, 6] ]
Expected Output
Is Symmetric: True