15 Ağustos 2012 Çarşamba

JAVADA BIGINTEGER SINIFI


 public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        System.out.println("Enter the number: ");
        BigInteger a = sc.nextBigInteger();
        System.out.println("Enter the pow: ");
        int exponent=sc.nextInt();
        System.out.println("Result: " + a.pow(exponent));
    }

CONSOLE : 
Result : 3273390607896141870013189696827599152216642046043064789483291368096133796404674554883270092325904157150886684127560071009217256545885393053328527589376


Hiç yorum yok:

Yorum Gönder