hulk815 hulk815
  • 03-06-2022
  • Computers and Technology
contestada

Write a java program as follows Write a method called powOfTwo that takes an integer as parameter, computes, and outputs it’s square

Respuesta :

Аноним Аноним
  • 03-06-2022

Answer:

public static int powOfTwo(int input) {

 return input*input;

}

You will have to call this method in main
for printing it, write

System.out.println(powOfTwo(your number));

in public static void main(str[]args) {

}

Ver imagen Аноним
Answer Link

Otras preguntas

Help wrong one on the last question
which statement is supported by the information in the table? as depth increases, the density of the layers increases. as depth increases, the density of the la
In which region of Mexico might you expect to find sinkholes. Why?
Marking brainliest What does do u see , what does it mean and why does it matter
amenazar a alguien con contar un secreto suyo con el fin de obtener dinero u otro beneficio
Give me the rate, time, and distance plus the amount of hours thanks
when is an ecosystem said to have high net primary productivity?
Which of Brazil’s climate zones has a good chance of snow •tropical wet/dry •tropical rain forest •temperate •semiarid
Which strategy often works for strengthening friendships? (A) Communicate honestly and openly. (B) Be judgmental. (C) Break the ice. (D) Work through a problem
16÷8×3-2+5= what is the correct answer?​