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

a machine makes 300 boxes in 15 minutes find the unit rate in boxes per hour
what was thomas paine's role in American revolution
Ebaluate the expression if A=2.4 B=0.237 C=9.94. C-2ab
The length of a rectangle is 5 times it’s width the perimeter is 84 feet. What is the length and width of the rectangle
The planet Pluto is 39.5 AU’s from the sun.How long does it take to go around the sun once.
as you move down a column what happens to the ionic radius?
What reasoning and explanations can be used when solving radical equations and how do extraneous solutions arise from radical equations?
A plane has an airspeed of 111 km/h. It is flying on a bearing of 79 degrees while there is a 25 km/h wind out of the northeast​ (bearing 225 degrees​). What ar
PLS HELP ME FIRST ONE TO ANSWER AND GETS IT RIGHT GETS BRAINLIEST
The curtain rises on an empty stage. It is late afternoon November, 1945. The rooms are dusty, the curtains in rags. Chairs and tables are overturned. The door