Define an array to be a 121 array if all its elements are either

美国程序员面试题 Define an array to be a 121 array if al…
Write a method named getExponent(n, p) that returns the largest exponent x such that px evenly divides n. If p is <= 1 the method should return -1.

美国程序员面试题 Write a method named getExponent(n, p) that re…