public class Power { public static void main(String[] args) { int base = 3, exponent = -4; double result = Math.pow(base, exponent); System.out.println("Output = " + result); } }
No comments: