public static void main(String args[]){
		System.out.println("Input the values");
		Scanner sc=new Scanner(System.in);
		int lowerLimit=0;
		int upperLimit=0;
		int length;
		int target[] = null;
		int dest[] = null;
		ArrayList arr=null;
		//while(sc.hasNext()){
			lowerLimit=sc.nextInt();
			upperLimit=sc.nextInt();
		//}
		length=upperLimit-lowerLimit;
		
		target = new int[length];
		dest = new int[length];
		arr=new ArrayList(length);
		
		for(int count=0;count<length;count++){
			target[count]=count+lowerLimit;
			//dest[count] =cycleLength(target[count]);	
			arr.add(count, cycleLength(target[count]));
		}	
		
		Collections.sort(arr);
		
		if(arr.size()>1)
			System.out.println(lowerLimit+" "+upperLimit+" "+arr.get(arr.size()-1));
		else
			System.out.println(lowerLimit+" "+upperLimit+" "+arr.get(0));
		
	}