corda/test/Simple.java
2008-11-02 15:25:51 -07:00

12 lines
226 B
Java

public class Simple {
public static int size(long v, int radix) {
int size = 0;
for (long n = v; n != 0; n /= radix) ++size;
return size;
}
public static void main(String[] args) {
size(42, 10);
}
}