Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 4 of 4

Thread: Java Math help please

  1. #1
    Junior Member
    Join Date
    Jul 2014
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Java Math help please

    The area of a square is stored in a double variable named area . Write an expression whose value is length of the diagonal of the square.




    Do I use math.sqrt?


  2. #2
    Member
    Join Date
    Mar 2012
    Location
    United States
    Posts
    118
    My Mood
    Inspired
    Thanks
    1
    Thanked 33 Times in 31 Posts

    Default Re: Java Math help please

    Hi rv498,
    If you take a look at the Pythagorean theorem you will be solving for C, and I believe you will come to a conclusion about using math.sqrt as well.

  3. #3
    Junior Member
    Join Date
    Jul 2014
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: Java Math help please

    thanks

  4. #4
    Junior Member
    Join Date
    Jul 2014
    Posts
    11
    Thanks
    0
    Thanked 1 Time in 1 Post

    Default Re: Java Math help please

    diagonal = √2*a by Pythagorean theorem.

Similar Threads

  1. Question about math.pow and math.sqrt
    By ggx7 in forum Java Theory & Questions
    Replies: 7
    Last Post: March 7th, 2014, 12:51 PM
  2. java.math help?
    By Bump247 in forum What's Wrong With My Code?
    Replies: 1
    Last Post: January 13th, 2014, 11:58 AM
  3. [SOLVED] Help with Math.tan and Math.atan
    By Dr.Code in forum Algorithms & Recursion
    Replies: 6
    Last Post: July 2nd, 2012, 05:54 AM
  4. Confusion with Math.toDegrees() and Math.toRadians(). Please help.
    By marksquall in forum Java Theory & Questions
    Replies: 3
    Last Post: June 23rd, 2011, 01:28 AM
  5. Math in Java?
    By [Kyle] in forum Java Theory & Questions
    Replies: 3
    Last Post: September 23rd, 2009, 12:21 PM