public class ConsTest{
public ConsTest(){
int i=0;
int j=3;
return;
}
public static void main(
String args[]){ConsTest t=new ConsTest();}
}
This compiles and runs perfectly
Java specifications says that a constructor body can have
a return statement but the return statement should not
have a expression
Can anybody explain then what is the purpose of
a return statement at all in a constructor body