emojigirl7200 emojigirl7200
  • 01-12-2021
  • Computers and Technology
contestada

How to square a number in java.

Respuesta :

emmaginative
emmaginative emmaginative
  • 01-12-2021

Answer:

num**2

Explanation:

To square a number in Java, you just take the number and use two asterisks (**) to denote an exponent, and then connect a 2 to it.

For example, if your number is 5:

5**2 in Java means 5^2, which is 25.

Just like how 5**3 in Java means 5^3.

Hope this helps.

Answer Link

Otras preguntas

Up to what percentage of an adult's healthy body weight is fluid?
sosceles trapezoid abcd has legs ab and cd and base bc ab=6y-6 bc=4y-7 and cd=7y-12 find the value of y
What is the structure of a sonnet?
All of the following are equivalent to 3:8=x:32 except 8:3 = 32:x 3:x = 8:32 x:8 = 3:32 8:32 = 3:x
what is this i'm so confused
Because of the green revolution, the average u.s. cornfield increased its yields by _____ during the 20th century.
What would happen to the planets in the solar system if the sun’s gravitational force were to suddenly disappear? A) They will stop spinning. B) They will fly
Which statement correctly describes the relationship between Italian city-states and the European Renaissance? A. The Renaissance began when Catholic leaders i
What was Lincoln's main goal during the civil war?
What was the major issue that affected Andrew Johnson's Plan?