JPMorganChase interview question

1) DSA question was around matrix