結果 : define a function in java