Behavior of below code like this.First declaration gives compiler error while second works fine, even we print result of second line its give output of 1270 not 02366. so is it any specific truncation or shifting in integer in such cases?
public static void main(String[] args) {
int i =01339;//compiler error out of int range
int j= 02366;//works fine
System.out.println(j); //value 1270
}