Subscribe

RSS Feed (xml)

Powered By

Skin Design:
Free Blogger Skins

Powered by Blogger

Wednesday, November 21, 2007

code for Math.copySign in java

public class FloastPointDemo {
public static void main(String[] args) {

// Returns a copySign of the first argument
double d = Math.copySign (1234.56, -1);
System.out.println ("Math.copySign (1234.56, -1) = " + d);
}
}

// Math.copySign (1234.56, -1) = -1234.56

No comments: