#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b;
  string s;
  cin >> a >> b >> s;
  bool ans = true;
  if(s[a] != '-') ans = false;
  for(int i = 0; i < a+b+1; i++) {
    if(i != a and (s[i] -'0' < 0 or s[i] -'0' > 9)) ans = false;
  }  
  cout << (ans ?"Yes" :"No") << "\n";
}