package no130; import java.io.IOException; import java.io.InputStream; import java.io.PrintWriter; import java.util.ArrayList; import java.util.InputMismatchException; import java.util.NoSuchElementException; public class Main { public static void main(String[] args) { IO io = new IO(); int n = io.nextInt(); ArrayList al = new ArrayList<>(n); for(int i=0;i al, int i) { if (i == -1) { return 0; } ArrayList g0 = new ArrayList<>(); ArrayList g1 = new ArrayList<>(); for(int n:al) { if (((n>>i)&1) == 0) { g0.add(n&~(1< Integer.MAX_VALUE) { throw new NumberFormatException(); } return (int) nl; } public char nextChar() { if (!hasNext()) { throw new NoSuchElementException(); } return (char) readByte(); } public double nextDouble() { return Double.parseDouble(next());} public int[] arrayInt(int n) { int[] a = new int[n]; for(int i=0;i