#include<iostream>
#include <stdio.h>
#include<string>
#include <cmath>
#include <algorithm>
#include <vector>
#include <cstdint>
#include <queue> 
#include <map>
#include <set>
#define MOD 1000000007
#define FOR(i,a,b) for(int i=(a);i<(b);i++)
#define REP(i,n)  FOR(i,0,n)
#define dump(x)  cout << #x << " = " << (x) << endl;
#define debug(x) cout << #x << " = " << (x) << " (L" << __LINE__ << ")" << " " << __FILE__ << endl;
typedef long long ll;
using namespace std;

int main(){

  int a,b;
  cin >> a >> b;
  
  string s;
  cin >> s;

  REP(i,a+b+1){
    if(i == a){
      if(s[i] != '-'){
      cout << "No" << endl; return 0;
    }
    else if(s[i] < '0' || s[i] > '9'){
      cout << "No" << endl; return 0;
    }
  }
    
    cout << "Yes" << endl;
  
 return 0;
}