In Java how do you convert a decimal number to base 36?

slavoj picture slavoj · Feb 21, 2011 · Viewed 59.1k times · Source

If I have a decimal number, how do I convert it to base 36 in Java?

Answer

Jeremiah Willcock picture Jeremiah Willcock · Feb 21, 2011

Given a number i, use Integer.toString(i, 36).