Question d’entretien chez Veeam Software

Given an integer maxVal and another integer a, return the biggest integer b such that a^b <= maxVal.