#include <stdio.h>
#include <stdlib.h>

int main() 
{
    int i;
    int  m,h[10000],n,s;
    m>=1;
    n>=1;
    m<=10000;
    n<=1000000;
    printf("please input:\n");
    scanf("%d%d",&n,&m);
    s=n;
    for(i=0;i<n;i++)
	{
		scanf("%d",&h[i]);
		
	}	
	for(i=0;i<n;i++)
	{
		s = s - h[i];
	}
	if(s>=0)
	  printf("%d",s);
	else 
	   printf("-1");
	return 0;
}