A3logics interview question

A snippet of code for a diagonal & reverse diagonal matrix in Python