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 man on a diet is losing four-tenths of a kilogram each day. How many days will it take him to lose 3.2 kilograms?
HELP!!! WILL MARK BRAINLIEST !! PLEASE GIVE A DETAILED ANSWER! Read the passage below. Then answer the question that follows using information and evidence fro
Simplify the expression using synthetic division. (9x3 – 69x2 + 132x – 60) ÷ (x – 5)
why there's a rainbow after the rain?
Which federal policy would violate the powers reserved to the states O negotiating with leaders of foreign countries D establishing military bases in state capi
WHY DO HUMAN RIGHT VIOLATIONS HAPPEN?
HELP PLEASEEE!!!!! SCHOOL START TOMORROW. NUMBER 21 and 22 ONLY
what is the surface area of the smaller cone
prove that the following term​
Please solve for b and select the correct answer from below.