/* package whatever; // don't place package name! */ import java.util.*; import java.lang.*; import java.io.*; /* Name of the class has to be "Main" only if the class is public. */ class Main { public static void main (String[] args) throws java.lang.Exception { // your code goes here BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); String[] line = br.readLine().split(" "); int N = Integer.parseInt(line[0]); int D = Integer.parseInt(line[1]); long K = Long.parseLong(line[2]); ArrayList map = new ArrayList(); for(int i=0;i ans.getDiff()){ ans = tmp; } } if(ans.getDiff()==0){ System.out.println(0); }else{ System.out.println(K*ans.getDiff()); System.out.println(ans.start + " " + ans.end); } } private static Ans calc(ArrayList map,int s,int d){ Ans ans = new Ans(); ans.start = s; ans.start_c = map.get(s); ans.end = ans.start; ans.end_c = ans.start_c; for(int i=s;i<=s+d&&i