Write the definition of a function named twice that receives an integer argument and returns an integer that is twice the value of the parameter.

Respuesta :

Answer: public static int methodName(int a, int b){

     a = a * 2;

     b = b * 2;

}

int result = doubling(5, 10);

System.out.println(result);

//result would be 10, 20

Explanation: