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

Who commissioned them to explore? Or were they self-funded?
the state fish of hawaii is the humuhumunukunukuapua'a.. did anyone know this?
Which kind of organism is more likely to be found as a fossil in amber a frog or a rabbit?
Please need help. Thank you
As of 2014, how many songs has Dolly Parton released that have reached No. 1 on the Billboard Country charts? 20 10 25 15
Our relationship with Enkai is essential to the tribe. Enkai is neither male nor female. The sky god is powerful, but can change from nurturing to vengeful dep
11/24 in simplest form in fraction
50 POINTS!!!! Leanne can clean a fish tank in 30 minutes. Karl can clean a fish tank in 20 minutes. If they work together, how many minutes does it take them to
Approximate 17.850 litres to the nearest 1/2 litre
In the play's final scene Shakespeare uses the prince's investigation to