import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String s = sc.nextLine();
        String[] split = s.split("[^0-9]");
        String tmp = "";

        for (int i = 0; i < split.length; i++){
            if (tmp.length() < split[i].length()){
                tmp = split[i];
            }
        }
        System.out.println(tmp);
    }
}