using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace AtCoder.Abc
{
    class QuestionB
    {
        public static void Main(string[] args)
        {
            var sw = new System.IO.StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false };
            Console.SetOut(sw);

            // 整数配列の入力
            var inputLongArray = Console.ReadLine().Split(' ').Select(i => int.Parse(i)).ToArray();

            // 文字列の入力
            string s = Console.ReadLine();

            string result = "Yes";

            if (s.Length != inputLongArray[0] + inputLongArray[1] + 1) {
                result = "No";
            }else if(s[inputLongArray[0]] != '-') {
                result = "No";
            } else if(int.TryParse(s.Substring(0, inputLongArray[0]), out var ss) == false) {
                result = "No";
            }else if (int.TryParse(s.Substring(inputLongArray[0] + 1), out var sss) == false) {
                result = "No";
            }

            Console.WriteLine(result);

            Console.Out.Flush();
        }
    }
}
