#include <stdio.h>

int main(){
  int a,b,c,d,e,f;
  char ch;
  c =scanf("%d%d",&a,&b);
  d = scanf("%d%c%d",&e,&ch,&f);
 if(c ==0||d ==0||(d !=(a+b)) printf("No");
{

  int count1,count2;
  while(e>0){
    e = e/10;
    count1 +=1;
  }
  while(f>0){
    f =f/10;
    count2 += 1;
  }
  
  if(a ==count1 &&b ==count2){
    printf("Yes");
  }else{
    printf("No");
  }
}
}