Java Double Number Truncate trunc(double x)

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

Description

trunc

License

Open Source License

Declaration

public static double trunc(double x) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {
    public static double trunc(double x) {
        return x - x % 1;
    }/*w ww  . java  2s .c o m*/
}

Related

  1. trunc(double value)
  2. trunc(double value, double threshold)
  3. trunc(double value, int dp)
  4. trunc(double value, int len)
  5. trunc(double x)
  6. trunc(double x, double y)
  7. trunc4(Double number)
  8. truncate(double d)