package yukicoder; import java.util.Scanner; public class yuki369 { public static void main(String[] args){ //System.out.println("helloWorld"); Scanner scan = new Scanner(System.in); int count = scan.nextInt(); int[] countArr = new int [count]; int addcount = 0; for (int i = 0; i < count; i++) { //countArr[count] = scan.nextInt(); //addcount += countArr[count]; addcount += scan.nextInt(); } int yukians = scan.nextInt(); //System.out.println("addcount" + addcount); //System.out.println("yukians" + yukians); System.out.println(addcount - yukians); } }