import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scan = new Scanner(System.in); int D = scan.nextInt(); int []a = new int[D + 1]; for(int i = 0; i <= D; i++) { a[i] = scan.nextInt(); } scan.close(); int r0 = a[0]; int f1 = sub(a, 1); int f2 = sub(a, -1); //double r1 = (double)(f1 - f2) / 2; //double r2 = -r0 + (double)(f1 + f2) / 2; int r1 = (f1 - f2) / 2; int r2 = -r0 + (f1 + f2) / 2; if(r2 == 0) { if(r1 == 0) { System.out.println(0); System.out.println(r0); }else { System.out.println(1); System.out.println(r0 + " " + r1); } }else { System.out.println(2); System.out.println(r0 + " " + r1 + " " + r2); } } public static int sub(int[] a, int k) { int t = a[0]; int x = 1; for(int i = 1; i < a.length; i++) { x = x * k; t += a[i] * x; } return t; } }