import java.util.Scanner;

/**
 * Created by Echizen on 2017/5/14.
 */
public class Main {
    public static void main(String[] args) {
        Scanner in=new Scanner(System.in);
        int num=in.nextInt();
        System.out.println(Integer.highestOneBit(num));
    }
} import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        Scanner in=new Scanner(System.in);
        int num=in.nextInt();
        System.out.println(Integer.highestOneBit(num));
    }
} Main public static void main(String[] args) {
        Scanner in=new Scanner(System.in);
        int num=in.nextInt();
        System.out.println(Integer.highestOneBit(num));
    } main {
        Scanner in=new Scanner(System.in);
        int num=in.nextInt();
        System.out.println(Integer.highestOneBit(num));
    } Scanner in=new Scanner(System.in); in new Scanner(System.in) int num=in.nextInt(); num in.nextInt() in.nextInt in System.out.println(Integer.highestOneBit(num)) System.out.println System.out System System.out Integer.highestOneBit(num) Integer.highestOneBit Integer num String[] args args public class Main {
    public static void main(String[] args) {
        Scanner in=new Scanner(System.in);
        int num=in.nextInt();
        System.out.println(Integer.highestOneBit(num));
    }
} public class Main {
    public static void main(String[] args) {
        Scanner in=new Scanner(System.in);
        int num=in.nextInt();
        System.out.println(Integer.highestOneBit(num));
    }
} Main
import java.util.Scanner;

/**
 * Created by Echizen on 2017/5/14.
 */
public class Main {
    public static void main(String[] args) {
        Scanner in=new Scanner(System.in);
        int num=in.nextInt();
        System.out.println(Integer.highestOneBit(num));
    }
}