import java.io.*; import java.util.*; class Main{ public static void main(String[] args)throws IOException { //入力 BufferedReader br=new BufferedReader(new InputStreamReader(System.in)); Scanner scan=new Scanner(System.in); int n=Integer.parseInt(br.readLine()); long[] a=new long[n]; for(int i=0;i