Java Abs abs(double x)

Here you can find the source of abs(double x)

Description

abs

License

Open Source License

Declaration

public static double abs(double x) 

Method Source Code

//package com.java2s;

public class Main {
    private static final long MASK_NON_SIGN_LONG = 0x7fffffffffffffffL;

    public static double abs(double x) {
        return Double.longBitsToDouble(MASK_NON_SIGN_LONG & Double.doubleToRawLongBits(x));
    }//from w  w w  .j  a v a 2 s.co  m
}

Related

  1. abs(double value)
  2. abs(double value)
  3. abs(double value)
  4. abs(double x)
  5. abs(double x)
  6. abs(double z)
  7. abs(double... values)
  8. abs(double[] arr)
  9. abs(double[] array)