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

Question 3 The Minority Leader is elected by the political party with the second most Senators. A) True B) False
Jose rides his bike for 5 minutes to travel 8 blocks he rides for 10 minutes to travel 16 blocks which value will complete the table
Select the correct answer. Dickens is known to use caricature in his stories to criticize social problems and the evils of society. Note the words he uses to de
how do i say sorry to fix a broken friendship
can someone please help mee
Ms. Jerome wants to buy identical boxes of art supplies for her 25 students. If she can spend no more than $375 on art supplies, what inequality describes the p
can someone please help mee
A reader who knows details about the historical period for a novel will most likely comprehend it better. True or false ? True False
Help with this please! I really confuse and don’t understand.
Help would be appreciated