Conversion from base 10 to base 18 writing a recursive and/or iterative method in Java