Pergunta de entrevista da empresa Rebel Foods (Formerly Faasos)

Given a matrix with row and column sorted, write a function to find the element. And then was asked for another and with better time complexity