diagonal

PythonF

Matrix Diagonal Pattern

Given an integer matrix of size N*N as input, the program must print only the diagonal elements. The remaining elements must be replaced by *…
PythonF

Diagonal Sum

A set of numbers forming a matrix N*N is passed as input. The program has to print the sum of numbers along the diagonals. Input Format: The…