@@ -0,0 +1,297 @@
+// Compute integer powers of 2.%0Aclass Power %7B%0A%09public static void main(String args%5B%5D) %7B%0A%09%09int e;%0A%09%09int result;%0A%09%09%0A%09%09for(int i = 0; i %3C 10; i++) %7B%0A%09%09%09result = 1;%0A%09%09%09e = i;%0A%09%09%09while(e %3E 0) %7B%0A%09%09%09%09result *= 2;%0A%09%09%09%09e--;%0A%09%09%09%7D%0A%09%09%09%0A%09%09%09System.out.println(%222 to the %22 + i + %22 power is %22 + result);%0A%09%09%7D%0A%09%7D%0A%7D%0A

Compute integer powers of 2 using while loop