For this code:
a = IntegerExponent[k,7]; (*a is highest power of 7 that divides k*)
I would like to find b, where b is:
b = IntegerPower[k,7]; (*b is highest power of 7 that is less than k*)
Is there an efficient way to implement a function to do that?