#include int main(){ //input int N; scanf("%d",&N); int total = 0; for (int i = 0;i < N;i++){ int A; scanf("%d",&A); total += A; } int v; scanf("%d",&v); //output printf("%d\n",total-v); return 0; }