Coding Fun Java Java Exponents

Java Exponents





This is the exact code you need to calculate exponents in java! ✅ Simply write Math.pow(a, b) and replace with the numbers you want.

?Start practicing now with 10 free java programs –
? Source Code –

“a” is your base and “b” is your exponent. For example, 5^2 would be Math.pow(5, 2); Put that in a print statement like this: System.out.println(5 + 10); and you will see the…

Tags: , , , , , , , , , , , , , , , , , , , , ,

4 thoughts on “Java Exponents”

  1. Neel Sheth says:

    Hey Alex Lee, I would really suggest making a video on all Math Library Functions.
    Though I know them, they Might be helpful for others.

    Functions like-
    1-Math.pow() — (You already did this in this video)
    2-Math.min()
    3-Math.max()
    4-Math.sqrt()
    5-Math.cbrt()
    6-Math.Log()
    7-Math.abs()
    8-Math.round()
    9-Math.ceil()
    10-Math.floor()

    And Just Incase you do not know them… (There is a 99.99% chance you know them cuz well… you are Alex Lee!)
    I could help you with it. 😉

    Good luck with your channel!
    I will get my friends to sub to you! 🙂

  2. Lubmus says:

    Bro how many vids more to complete the java basics?
    I was wondering if you could make some android studio tutorials too.
    Thank you ??

  3. Jino Lim says:

    Nice tutorial but exponents are usually easy to understand in Java right away.

    Also, any idea how I can get input from the keyboard to perform an action in Java?
    Thanks!

Leave a Reply

Your email address will not be published. Required fields are marked *