Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

java log base 2

public static int log2(int x)
{
    return (int) (Math.log(x) / Math.log(2));
}
Source by www.techiedelight.com #
 
PREVIOUS NEXT
Tagged: #java #log #base
ADD COMMENT
Topic
Name
5+9 =