Online Java Compiler By
JavaTpoint.com
import java.math.BigInteger; public class BigIntegerSignumExample2 { public static void main(String[] args) { //create a BigInteger objects BigInteger big1; int result; // initialize BigInteger object big1=new BigInteger("-10"); //perform signum operation on big1 result=big1.signum(); String str="For "+big1+", Signum function returns "+result; System.out.println(str); } }
Output