You can write return statement in finally block but the value returned from try block will be updated on the stack and not the finally block return value.
Let us say you have this function
private Integer getnumber(){
Integer i = null;
try{
i = new Integer(5);
return i;
}catch(Exception e){return 0;}
finally{
i = new Integer(7);
System.out.println(i);
}
}
and you are calling this from main method
public static void main(String[] args){
System.out.println(getNumber());
}
This prints
7
5