Integer.rotateLeft(int i, int distance) has the following syntax.
public static int rotateLeft(int i, int distance)
In the following code shows how to use Integer.rotateLeft(int i, int distance) method.
public class Main { public static void main(String[] args) { System.out.println(Integer.rotateLeft(10,2)); } }
The output:
The code above rotates value 10 to left for distance of 2.