fun main(array: Array<String>) {
    val (a, b) = readLine()!!.split(" ").map{ it.toInt() }
    val s = readLine()!!

    repeat(a) {
        if(s[it] !in '0'..'9') {
            print("No")
            return
        }
    }
    if(s[a] != '-') {
        print("No")
        return
    }
    for(i in a+1 until a+b) {
        if(s[i] !in '0'..'9') {
            print("No")
            return
        }
    }
    print("Yes")
}