Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /**
- * Project: Advanced_Loops - created by borkins on 2017-04-08.
- */
- import java.util.Scanner;
- public class _04_EvenPowersOf2
- {
- public static void main(String[] args)
- {
- Scanner console = new Scanner(System.in);
- int n = Integer.parseInt(console.nextLine());
- long nPow = 1 << n;
- for (long i = 1; i <= nPow; i <<= 2) {
- System.out.println(i);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment