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

We're does the thousand go in 5462.9554
After clicking the Start button on your computer screen desktop, what option would you then select to examine system components you might want to modify? A. F
What brought an end to the dominance of the Silk Road
What is the percent of 110 to 275
James has a board that is 3/4 foot long. He wants to cut the board into pieces that are 1/8 foot long. How many pieces can James cut from the board
the oscillations producing a light wave are
Equation: y=15x+60 Statement of the effects on the parent function of the given "m" and "b" as well as the different terms used to describe "m" and "b"
Which weighs more 2.5 pounds of rocks or 40 ounces of feathers
After clicking the Start button on your computer screen desktop, what option would you then select to examine system components you might want to modify? A. F
(link to the maths question) can anyone help?