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

URGENT!! Find the slope and intercept of the line with the equation 10x + 2y = 36.
7x7x7x7x7x7= ______ to the power of _____ .
!!Urgent!! The triangles shown are:
Based on the context, what is the meaning of schadenfreude? A.pleasure in another’s misfortune B.feeling of great importance C.understandable urgency D.suspic
How does energy from the Sun travel to Earth? through radiation through convection through conduction through the movement of particles
Explain how to solve the equation b - 7 = 12
What will be the long-term consequences if the hunts of baby deer continue? If they stop?
What are the like terms in the following algebraic expression? 5 - 3y + 2x - 5y + x - 2 + 3x^2
Like charges will exert a force ofa. positiveb. negativec. attractiond. repulsione. neutral​
what is the area of the house type shape outlined in blue this is a maths test could u please show working if u can answer it bc we must show working plz I coul