ZhenlongDai/ACPR huggingface dataset:
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
from collections import Counter
a,b = map(int,input().split())
s = input()

if s.count('-')==1:
    li = s.split('-')
    if len(li[0])==a and len(li[1])==b:
        print('Yes')
else:
    print('No')



Failing test case input:
0 0
.-*

Expected output:
No


Actual output:

Fixed submission (verdict: Accepted):
from collections import Counter
a,b = map(int,input().split())
s = input()

if s[a]=='-' and '-' not in s[0:a] and '-' not in s[a+1:]:
    print('Yes')
else:
    print('No')

Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
def resolve():
    A, B = map(int, input().split())
    S = input()
    C = "1234567890"
    for i in range(len(S)):
        if i == A:
            if S[i] == "-":
                continue
            else:
                print("No")
                exit()
            if S[i] in C:
                continue
            else:
                print("No")
                exit()
    print("Yes")
    exit()
resolve()

Failing test case input:
-1 1
10506

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
def resolve():
    A, B = map(int, input().split())
    S = input()
    C = "1234567890"
    for i in range(A):
        if S[i] in C:
            continue
        else:
            print("No")
            exit()
    if S[A] != "-":
        print("No")
        exit()
    for i in range(A+1, len(S)):
        if S[i] in C:
            continue
        else:
            print("No")
            exit()
    print("Yes")
resolve()

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b=map(int,input().split())
s=input()
print('NYoe s'[s.replace('-','').isdigit() and s.find('-')==a and len(s)==a+b+1::2])

Failing test case input:
-1 2
76

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a,b=map(int,input().split())
s=input()
print('NYoe s'[s.replace('-','').isdigit() and s.find('-')==a and len(s)==a+b+1 and s.count('-')==1::2])

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a, b = map(int, input().split())
s = input()

if len(s) == a+b+1 and s[a] == '-':
    print('Yes')
else:
    print('No')

Failing test case input:
1 1
---

Expected output:
No

Actual output:
Yes


Fixed submission (verdict: Accepted):
a, b = map(int, input().split())
s = input()

if len(s) == a+b+1 and s[a] == '-' \
    and s[:a].isdecimal() and s[a+1:].isdecimal():
    print('Yes')
else:
    print('No')

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a, b = map(int, input().split())
s = input('')
if len(s) == (a+b+1) and s[a]=='-':
    print('Yes')
else:
    print('No')

Failing test case input:
1 1
---

Expected output:
No

Actual output:
Yes


Fixed submission (verdict: Accepted):
a, b = map(int, input().split())
s = input('')

if len(s) == (a+b+1) and s[a]== '-'  and s.count('-') ==1:
    print('Yes')
else:
    print('No')
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):

a , b = map(int,input().split())
c = input()
d = len(c)
e = 0
for i in range(d):
    if c[i] =="-" and i != a:
        e = e + 1
if a+b+1 == d and c[a] =="-" and e > 0:
    
    print("Yes")
else:
    print("No")

Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):

a , b = map(int,input().split())
c = input()
d = len(c)
e = 0
for i in range(d):
    if c[i] =="-" and i != a:
        e = e + 1
if a+b+1 == d and c[a] =="-" and e == 0:
    
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b = map(int,input().split())
s = input()
if s.count('-') == 1:
    s = s.split('-')
    if len('-'.join(s)) == a+b+1:
        print('Yes')
    else:
        print('No')
else:
    print('No')

Failing test case input:
6 1
269-6650

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
s = input()

if s.count('-') == 1:
    S = s.split('-')
    if len('-'.join(S)) == a+b+1 and len(S[0]) == a and len(S[1]) == b:
        print('Yes')
    else:
        print('No')
else:
    print('No')

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A, B = map(int, input().split())
S = input()
flag = False
for i in range(len(S)):
    if i == A:
        if S[i]=="-":
            flag = True
        else:
            flag = False
    else:
        if S[i]=="-":
            flag = False
print("Yes") if flag else print("No")

Failing test case input:
2 -1
-+-

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
A, B = map(int, input().split())
S = input()
flag = False
for i in range(len(S)):
    if i == A:
        if S[i]=="-":
            flag = True
    else:
        if S[i]=="-":
            flag = False
            break
print("Yes")if flag else print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A,B=map(int,input().split())
S=input()


if(len(S[:A])==A and S[A]=='-' and len(S[A+1:])==B):
  print('Yes')
else:print('No')

Failing test case input:
1 1
---

Expected output:
No

Actual output:
Yes


Fixed submission (verdict: Accepted):
A,B=map(int,input().split())
S=input()


if(len(S[:A])==A and S[A]=='-' and len(S[A+1:])==B and S.count('-')==1):
  print('Yes')
else:print('No')

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A,B=map(int,input().split())
S=input()
if (S[0:A].isdecimal()==True) and (S[A+1:-1].isdecimal()==True):
    print('Yes')
else:
    print('No')

Failing test case input:
-1 1
16443

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
A,B=map(int,input().split())
S=input()
if S[:A].isdecimal() and S[A+1:].isdecimal() and S.count('-')==1 and len(S)==(A+B+1):
    print('Yes')
else:
    print('No')
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b = map(int, input().split())
s = input()
if len(s) == a+b+1:
    print("Yes")
else:
    print("No")

Failing test case input:
1 1
---

Expected output:
No

Actual output:
Yes


Fixed submission (verdict: Accepted):
a,b = map(int, input().split())
s = input()
if len(s) == a+b+1 and s.count("-") == 1 and s[a] == "-":
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import re

A, B = map(int, input().split())
S = input()

pattern = '[0-9]{A}-[0-9]{B}'
result = re.match(pattern, S)

if result:
  print('Yes')
else:
  print('No')

Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
import re

A, B = map(int, input().split())
S = input()

pattern = '[0-9]{' + str(A) + '}-[0-9]{' + str(B) + '}'
result = re.match(pattern, S)


if result:
  print('Yes')
else:
  print('No')

Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
a,b = map(int,input().split())
s = input()

lst = s.split("-")

if len(lst[0]) == a and len(lst[-1]) == b:
    print("Yes")
else:
    print("no")

Failing test case input:
-1 0
.-*

Expected output:
No


Actual output:
no


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
s = input()

lst = s.split("-")

if len(lst[0]) == a and len(lst[1]) == b and len(lst) == 2:
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
x,y=map(int, input().split())
S=input()
if len(S)==x+y+1 and S[x]=='-':
  print('Yes')
else:
  print('No')


Failing test case input:
1 1
---

Expected output:
No

Actual output:
Yes


Fixed submission (verdict: Accepted):
x,y=map(int, input().split())
S=input()
if len(S)==x+y+1 and S[x]=='-' and S.count('-')==1:
  print('Yes')
else:
  print('No')

Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
import math
def py():
    print("Yes")
def pn():
    print("No")
def iin():
    x = int(input())
    return x

neko = 0
nya = 0
nuko = 0

a,b = map(int,input().split())
s = input()
for x in range(len(s)):
    if s[x] == '-':
        break
if (a == x)and(b == len(s)-1-x):
    py()
else:
    pn()

Failing test case input:
0 0
5

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
import math
def py():
    print("Yes")
def pn():
    print("No")
def iin():
    x = int(input())
    return x

neko = 0
nya = 0
nuko = 0

a,b = map(int,input().split())
s = input()
for x in range(len(s)):
    if s[x] == '-':
        neko = x
        nya+=1
if nya != 1:
    pn()
elif (a == neko)and(b == len(s)-1-neko):
    py()
else:
    pn()
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A,B = (int(i) for i in input().split())
S = input()



if(('-' in S) and (A+B+1==len(S))):
    if(S.count("-") != 1):
        print("No")
    else:
        print("Yes")
else:
    print("No")


Failing test case input:
6 1
269-6650

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
A,B = (int(i) for i in input().split())
S = input()

if(S.count("-")==1 and (A+B+1==len(S)) and S.find("-")==A):
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A, B = map(int,input().split())
S = list(input())
if S.count("-") == 1 and S[A] == "-":
    print("yes")
else:
    print("No")

Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
yes


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
s=input()
if s[a]=="-" and s.count("-")==1:
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
a,b = map(int,input().split())
s = input()

lst = s.split("-")

if len(lst[0]) == a and len(lst[1]) == b:
    print("Yes")
else:
    print("no")

Failing test case input:
0 2
55

Expected output:
No


Actual output:
no


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
s = input()

lst = s.split("-")

if len(lst[0]) == a and len(lst[1]) == b and len(lst) == 2:
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):




def main():
    A, B = map(int, input().split())
    S = input().split('-')
    print('Yes'if all([s.isdigit() for s in S])and len(S) == 2 else 'No')


if __name__ == "__main__":
    main()


Failing test case input:
6 2
0566-962

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):




def main():
    A, B = map(int, input().split())
    S = input()
    N = S[:A] + S[A + 1:]

    print("Yes" if S[A] == "-" and N.isdigit() else "No")


if __name__ == "__main__":
    main()

Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
a,b = map(int,input().split())
s = input()

lst = s.split("-")

if len(lst[0]) == a and len(lst[1]) == b and len(lst) == 2:
    print("Yes")
else:
    print("no")

Failing test case input:
6 3
0566-962

Expected output:
No


Actual output:
no


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
s = input()

lst = s.split("-")

if len(lst[0]) == a and len(lst[1]) == b and len(lst) == 2:
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b=map(int,input().split());s=input()
try:
  int(s[:a])
  int(s[a+1:])
  if s[a]=="-":
    print("Yes")
except:
  print("No")


Failing test case input:
-1 1
104

Expected output:
No


Actual output:

Fixed submission (verdict: Accepted):
a,b=map(int,input().split());s=input()
try:
  int(s[:a])
  int(s[a+1:])
  print(["No","Yes"][s[a]=="-"])
except:
  print("No")
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a, b = map(int,input().split())
s = input()

if s.count("-") == 0 or s.count("-") > 1:
  print("No")
  exit()

if s[0] == "-" or s[-1] == "-":
  print("No")
  exit()

print("Yes")

Failing test case input:
-1 0
.-*

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a, b = map(int,input().split())
s = input()

if s.count("-") == 0 or s.count("-") > 1:
  print("No")
  exit()

if s[0] == "-" or s[-1] == "-":
  print("No")
  exit()

if len(s.split("-")[0]) != a:
  print("No")
else:
  print("Yes")

Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
import re
a,b=input().split()
s=input()
match = re.search("\d{a}-\d{b}",s)
if match:
  print('Yes')
else:
  print('No')

Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
import re
a,b=input().split()
s=input()
pat ="^\d{"+a+"}-\d{"+b+"}$"
match = re.search(pat,s)
if match:
  print('Yes')
else:
  print('No')

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import re
a, b = [int(i) for i in input().split()]
print("Yes" if re.match(r"^\d{3}-\d{4}$", input()) else "No")

Failing test case input:
6 8
269-6650

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
import re
a, b = [int(i) for i in input().split()]
print("Yes" if re.match("^\\d{%d}-\\d{%d}$" % (a, b), input()) else "No")

Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
def resolve():
    a, b = map(int, input().split())
    s = input()
    
    flag_len = False
    flag_bar = False
    flag_num = True
    if a+b+1 == len(s):
        flag_len = True
    if s.count("-") == 1:
        flag_bar = True
    if flag_len and flag_bar:
        for c in s:
            code = ord(c)
            if code < ord("0") or ord("9") < code:
                if code!= ord("-"):
                    flag_num == False
                    break
    if flag_len and flag_bar and flag_num:
        print("Yes")
    else:
        print("No")
resolve()

Failing test case input:
6 1
269-6650

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
def resolve():
    a, b = map(int, input().split())
    s = input()
    
    flag_len = False
    flag_bar = False
    flag_num = True
    if a+b+1 == len(s):
        flag_len = True
    if s.count("-") == 1 and s[a] == "-":
        flag_bar = True
    if flag_len and flag_bar:
        for i in range(len(s)):
            code = ord(s[i])
            if code < ord("0") or ord("9") < code:
                if code!= ord("-"):
                    flag_num == False
                    break
                
    if flag_len and flag_bar and flag_num:
        print("Yes")
    else:
        print("No")
resolve()
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A, B = map(int, input().split())
S = input()
falg = False

if S.count('-') == 1: 
  code_1, code_2 = S.split('-')
  if (len(code_1) == A) and (len(code_2) == B):
    flag = True
  else:
    flag = False

  if (code_1+code_2).isdecimal():
    flag = True
  else:
    flag = False

else:
  flag = False
        
if flag:
  print('Yes')
else:
  print('No')

Failing test case input:
6 4
269-6650

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
A, B = map(int, input().split())
S = input()
falg = False

if S.count('-') == 1: 
  code_1, code_2 = S.split('-')
  if (len(code_1) == A) and (len(code_2) == B):
    flag = True
  else:
    flag = False

  if (code_1+code_2).isdecimal() and flag:
    flag = True
  else:
    flag = False

else:
  flag = False
        
if flag:
  print('Yes')
else:
  print('No')

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b = map(int,input().split())
S = input()
def crazy(a,b,S):
    num = "0123456789"
    if S[a] != "-":
        return False
    for i in S[:a]:
        if i not in num:
            return False
    return True

if crazy(a,b,S):
    print("Yes")
else:
    print("No")

Failing test case input:
0 1
-,-

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
S = input()
def crazy(a,b,S):
    num = "0123456789"
    if S[a] != "-":
        return False
    for i in S[:a]:
        if i not in num:
            return False
    for i in S[a + 1:]:
        if i not in num:
            return False
    return True

if crazy(a,b,S):
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
def resolve():
    
    A, B = [int(item) for item in input().split()]
    S = input()

    if S[A] == '-':
        if '-' in S[:A] and '-' in S[-1*B:]:
            print('No')
        else:
            print('Yes')
    else:
        print('No')
if __name__ == "__main__":
    resolve()


Failing test case input:
0 1
-,-

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
def resolve():
    
    A, B = [int(item) for item in input().split()]
    S = input()

    if S[A] == '-' and len(S) >= 3:
        if '-' in S[:A] or '-' in S[-1*B:]:
            print('No')
        else:
            print('Yes')
    else:
        print('No')
if __name__ == "__main__":
    resolve()

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A,B = (int(i) for i in input().split())
S = str(input())

if S[A] != '-' or S[:A]in '-' or S[-B:] in '-':
    print('No')

else:
    print('Yes')


Failing test case input:
1 0
,--

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
A,B = (int(i) for i in input().split())
S = str(input())
if S[A] != "-" or "-" in S[:A] or "-" in S[-B:]:
    print('No')

else:
    print('Yes')
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b = map(int,input().split())
s = input()
print("Yes" if s[a]=="-" else "No")

Failing test case input:
2 -2
-+-

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
s = input()
print("Yes" if s[a]=="-" and s.count("-")==1 else "No")

Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
import sys
a,b = map(int,input().split())
s = list(input())
if s[a] != "-":
	print("No")
	sys.exit()
else:
	print("Yes")

Failing test case input:
0 1
-,-

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
import sys
a,b = map(int,input().split())
s = list(input())
if s[a] != "-":
	print("No")
	sys.exit()
s[a] = 1
if not "-" in s:
	print("Yes")
else:
	print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):

a,b = (int(i) for i in input().split())
s = input()
print(a,b,s[0:a],s[a],s[a+1:])

a = int(a)
b = int(b)

if(len(s)==(a+b+1) and s[0:a].isdigit() and s[a]=="-" and s[a+1:].isdigit()):
    print("Yes")
else:
    print("No")

Failing test case input:
0 4
7444

Expected output:
No


Actual output:
0 4  7 444
No


Fixed submission (verdict: Accepted):

a,b = (int(i) for i in input().split())
s = input()

a = int(a)
b = int(b)

if(len(s)==(a+b+1) and s[0:a].isdigit() and s[a]=="-" and s[a+1:].isdigit()):
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a ,b = (map(int,input().split()))
post = input().split("-")

if len(post) == 2:
    if(len(post[0])==a and len(post[1])==b):
        print("YES")
    else:
        print("NO")
else:
    print("NO")

Failing test case input:
0 -1
),.

Expected output:
No


Actual output:
NO


Fixed submission (verdict: Accepted):
a ,b = (map(int,input().split()))
post = input().split("-")

if len(post) == 2:
    if(len(post[0])==a and len(post[1])==b):
        print("Yes")
    else:
        print("No")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
a,b=map(int,input().split())
N=list(str(input()))
if N[a]=="-":
  print("Yes")
else:
  print("No")

Failing test case input:
1 0
---

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a,b=map(int,input().split())
N=list(str(input()))
if N[a]=="-":
  N.pop(a)
  if "-" in N:
    print("No")
  else:
    print("Yes")
else:
  print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b = map(int,input().split())
s = str(input())
if s.count('_') == 1 and s[a]== '_':
    print("Yes")
else:
    print("No")

Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
s = str(input())
if s.count('-') == 1 and s[a]== '-':
    print("Yes")
else:
    print("No")
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a, b = map(int, input().split())
s = input()
if s[:a].isdecimal() and s[-b:].isdecimal():
  print("Yes")
else:
  print("No")

Failing test case input:
1 2
7444

Expected output:
No

Actual output:
Yes


Fixed submission (verdict: Accepted):
a, b = map(int, input().split())
s = input()
if s[:a].isdecimal() and s[a] == "-" and s[-b:].isdecimal():
  print("Yes")
else:
  print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
def main():
    a, b = map(int, input().split())
    s = input()

    if s[a] != '-':
        print('No')
    else:
        print(s[:a], s[a+1:])
        if s[:a].isdigit() and s[-b:].isdigit():
            print('Yes')
        else:
            print('No')


if __name__ == "__main__":
    main()


Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
269 6650
Yes


Fixed submission (verdict: Accepted):
def main():
    a, b = map(int, input().split())
    s = input()

    if s[a] != '-':
        print('No')
    else:
        if s[:a].isdigit() and s[-b:].isdigit():
            print('Yes')
        else:
            print('No')


if __name__ == "__main__":
    main()

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A, B = map(int, input().split())
S = input()
flag = False
for i in range(len(S)):
    if i == A:
        if S[i]=="-":
            flag = True
    else:
        if S[i]=="-":
            flag = False
print("Yes") if flag else print("No")

Failing test case input:
2 -2
-+-

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
A, B = map(int, input().split())
S = input()
flag = False
for i in range(len(S)):
    if i == A:
        if S[i]=="-":
            flag = True
    else:
        if S[i]=="-":
            flag = False
            break
print("Yes")if flag else print("No")

Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
a,b = map(int,input().split())
s = input()
if len(s) == a + b + 1:
    if s[a] == "-":
        s = s.replace("-","")
        print(s)
        if s.isdecimal():
            print("Yes")
        else:
            print("No")
    else:
        print("No")
else:
    print("No")

Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
2696650
Yes


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
s = input()
if len(s) == a + b + 1:
    if s[a] == "-":
        s = s.replace("-","")
        if s.isdecimal() and len(s) == a + b:
            print("Yes")
        else:
            print("No")
    else:
        print("No")
else:
    print("No")
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import re

A, B = map(int, input().split())
S = input()

pattern = '[0-9]{¥A}-[0-9]{¥B}'
result = re.match(pattern, S)


if result:
  print('Yes')
else:
  print('No')

Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
import re

A, B = map(int, input().split())
S = input()

pattern = '[0-9]{' + str(A) + '}-[0-9]{' + str(B) + '}'
result = re.match(pattern, S)


if result:
  print('Yes')
else:
  print('No')

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A, B = map(int, input().split())
S = input()

flag = True

if S[A] != "-":
	flag = False
elif len(S) != A+B+1:
	flag = False

S = S[:A] + S[A+1:]

if not S.isdigit():
	flag = False
else:
	flag = True

print("Yes") if flag == True else print("No")

Failing test case input:
0 0
31

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
A, B = map(int, input().split())
S = input()

def judge(S):
	if S[A] != "-":
		return False
	if len(S) != A+B+1:
		return False

	S = S[:A] + S[A+1:]

	if not S.isdigit():
		return False
	return True

print("Yes") if judge(S) else print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a, b = map(int,input().split())
s = input()
if len(s) == a+b+1 and s.count('-') == 1:
  print("Yes")
else:
  print("No")
  exit(0)

s1,s2 = s.split('-')
if a == len(s1) and b == len(s2):
  print("Yes")
else:
  print("No")


Failing test case input:
6 1
269-6650

Expected output:
No


Actual output:
Yes
No


Fixed submission (verdict: Accepted):
a, b = map(int,input().split())
s = input()
if len(s) == a+b+1 and s.count('-') == 1:
  pass
else:
  print("No")
  exit(0)

s1,s2 = s.split('-')
if a == len(s1) and b == len(s2):
  print("Yes")
else:
  print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b = map(int, input().split())
s = input()
if len(s) == a+b+1 and s.count("-") == 1:
    print("Yes")
else:
    print("No")

Failing test case input:
6 1
269-6650

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a,b = map(int, input().split())
s = input()
if len(s) == a+b+1 and s.count("-") == 1 and s[a] == "-":
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import sys
A,B = [int(n) for n in input().split()]

S = str(input())
if(S[A] != "-"):
    print("No")
    sys.exit()
S = S[:A] + S[A+1:]
L = len(S)
table = [n for n in range(10)]
for s in S:
    if not( s in table):
        print("No")
        sys.exit()
print("Yes")


Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
import sys
A,B = [int(n) for n in input().split()]

S = str(input())
if(S[A] != "-"):
    print("No")
    sys.exit()
S = S[:A] + S[A+1:]
table = [str(n) for n in range(10)]
for s in S:
    if not( s in table):
        print("No")
        sys.exit()
print("Yes")
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b=map(int,input().split())
s=input()
try:
  if s[:a].isdecimal()==True and s[a+1:].dicimal()==True:
    print("Yes" if s[:a]+"-"+s[a+1:]==s else "No")
  else:
    print("No")
except:
  print("No")

Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
a,b=map(int,input().split())
s=input()
try:
  if s[:a].isdecimal()==True and s[a+1:].isdecimal()==True:
    print("Yes" if s[:a]+"-"+s[a+1:]==s else "No")
  else:
    print("No")
except:
  print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b=map(int,input().split())
s=input()
print(s)
if s[a]!="-":
    print("No")
    
elif s.count("-")>1:
    print("No")
    
else:
    s=s.replace("-","")
    
    
    if s.isdigit()==True:
        print("Yes")
    else:
        print("No")

Failing test case input:
0 -1
.+-

Expected output:
No


Actual output:
.+-
No


Fixed submission (verdict: Accepted):

a,b=map(int,input().split())
s=input()

if s[a]!="-":
    print("No")
    
elif s.count("-")>1:
    print("No")
    
else:
    s=s.replace("-","")
    
    
    if s.isdigit()==True:
        print("Yes")
    else:
        print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import collections


def inputStrOnebyOne():
    s = list(input())
    return s


def inputOnebyOne_Int():
    a = list(int(x) for x in input().split())
    return a

def main():
    a,b = input().split()
    s = input()
    if s.count("-") == 1:
        c,d = s.split("-")
        if a == str(len(c)) and b == str(len(d)):
            print("Yes")
    else:
        print("No")

if __name__=='__main__':
    main()

Failing test case input:
2 0
-+,

Expected output:
No


Actual output:

Fixed submission (verdict: Accepted):
import collections


def inputStrOnebyOne():
    s = list(input())
    return s


def inputOnebyOne_Int():
    a = list(int(x) for x in input().split())
    return a

def main():
    a,b = input().split()
    s = input()
    if s.count("-") == 1:
        c,d = s.split("-")
        if a == str(len(c)) and b == str(len(d)):
            print("Yes")
        else:
            print("No")
    else:
        print("No")

if __name__=='__main__':
    main()

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import re

A, B = map(int, input().split())
S = input()

result = re.match('[0-9]{A}-[0-9]{B}', S)

if result:
  print('Yes')
else:
  print('No')

Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
import re

A, B = map(int, input().split())
S = input()

pattern = '[0-9]{' + str(A) + '}-[0-9]{' + str(B) + '}'
result = re.match(pattern, S)


if result:
  print('Yes')
else:
  print('No')
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b=map(int,input().split())
s=input()
if len(s)<11 and s[a]=="-":
  print("Yes")
else:
  print("No")

Failing test case input:
0 -1
-+-

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a,b=map(int,input().split())
s=input()
if s.count("-")<2 and s[a]=="-":
  print("Yes")
else:
  print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A,B=map(int, input().split())
S=input()

flag=True
if S[A]!='-':
    flag=False
a=S[:A]
b=S[A+1:]
print(a)
print(b)
if not(a.isdigit() and b.isdigit()):
    flag=False
if flag:
    print('Yes')
else:
    print('No')


Failing test case input:
1 0
---

Expected output:
No


Actual output:
-
-
No


Fixed submission (verdict: Accepted):
A,B=map(int, input().split())
S=input()

flag=True
if S[A]!='-':
    flag=False
a=S[:A]
b=S[A+1:]
if not(a.isdigit() and b.isdigit()):
    flag=False
if flag:
    print('Yes')
else:
    print('No')

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b=map(int,input().split())
s=input()
d=s[:a]+s[a+1:]
if s[a]=='-' and '-' not in d:
  print('YES')
else:
  print('NO')

Failing test case input:
-1 1
57

Expected output:
No


Actual output:
NO


Fixed submission (verdict: Accepted):
a,b=map(int,input().split())
s=input()
d=s[:a]+s[a+1:]
if s[a]=='-' and '-' not in d:
  print('Yes')
else:
  print('No')

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A,B =map(int,input().split())
hih=0
num=1
S=str(input())
S= list(S)
for s in S:
    if num==A and s=="-":
        hih=1
    num+=1
if hih==1:
    print("Yes")
else:
    print("No")

Failing test case input:
1 2
---

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):

A,B =map(int,input().split())
hih=0
num=1
test=1
S=str(input())
S= list(S)
for s in S:
    if num==A+1 and s=="-":
        hih=1
    if num!=A+1 and s=="-":
        test=0
        
    
    num+=1
if hih==1 and test==1:
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A, B = list(map(int, input().split()))
S = input()

flag = 0

for i in range(len(S)):
    if S[i] == '-':
        if i == A:
            flag = 1
        else:
            flag = 0

if flag == 1:
    print("Yes")
else:
    print("No")


Failing test case input:
2 -1
-+-

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
A, B = list(map(int, input().split()))
S = input()

flag = 0

for i in range(len(S)):
    if S[i] == '-':
        if i == A:
            flag = 1
        else:
            flag = 0
            break

if flag == 1:
    print("Yes")
else:
    print("No")
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import re
a,b=map(int,input().split())
s=input()
if re.search(r"^([0-9])*$",s[:a]) and s[a]=="-" and re.search(r"^([0-9])$",s[a+1:]) and len(s)==a+b+1:
    print("Yes")
else:
    print("No")

Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
import re
a,b=map(int,input().split())
s=input()
if re.search(r"^([0-9])*$",s[:a]) and s[a]=="-" and re.search(r"^([0-9])*$",s[a+1:]) and len(s)==a+b+1:
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
import re


def answer(a: int, b: int, s: str) -> str:
    pattern = r'\d{1,5}-\d{1,5}'
    if re.match(pattern, s):
        return 'Yes'
    return 'No'


def main():
    a, b = map(int, input().split())
    s = input()
    print(answer(a, b, s))


if __name__ == '__main__':
    main()


Failing test case input:
6 2
269-665/

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
import re


def answer(a: int, b: int, s: str) -> str:
    pattern = fr'\d{{{a}}}-\d{{{b}}}'
    if re.match(pattern, s):
        return 'Yes'
    return 'No'


def main():
    a, b = map(int, input().split())
    s = input()
    print(answer(a, b, s))


if __name__ == '__main__':
    main()

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import sys

a,b=map(int,input().split())
try:
	s=input()
	sa=int(s[:a])
	ss=s[a]
	sb=int(s[a+1:])
	if ss!='-':
		print("No")
		sys.exit()
	print("Yes")
except:
	print("No")

Failing test case input:
-1 2
31

Expected output:
No


Actual output:
No
No


Fixed submission (verdict: Accepted):
a,b=map(int,input().split())
try:
	s=input()
	sa=int(s[:a])
	ss=s[a]
	sb=int(s[a+1:])
	print("Yes" if ss=='-' else "No")
except:
	print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b=input().split()
s=input()
print("Yes" if s[int(a)]=="_" and s.count("_")==1 else "No")

Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
a,b=input().split()
s=input()
print("Yes" if s[int(a)]=="-" and s.count("-")==1 else "No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a, b = map(int,input().split())
s = input()
s
print(('No','Yes')[len(s) == (a + b + 1) and s[a] == '-'])



Failing test case input:
1 1
---

Expected output:
No

Actual output:
Yes


Fixed submission (verdict: Accepted):
a, b = map(int,input().split())
s = input()
print(('No','Yes')[len(s) == (a + b + 1) and s[a] == '-' and list(s).count('-')==1 ])

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):

import re

a, b = map(int, input().split(' '))
s = input()
if re.match('^(\d{3}-\d{4})$', s):
    print('Yes')
else:
    print('No')



Failing test case input:
6 8
269-6650

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):

import re

X = input().split(' ')

s = input()
if re.match('^(\d{' + X[0] + '}-\d{'+ X[1]+ '})$', s):
    print('Yes')
else:
    print('No')
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b = map(int,input().split())
s = input()
if len(s)==a+b+1 and s[a]=="-":
    print("Yes")
else:
    print("No")

Failing test case input:
1 1
---

Expected output:
No

Actual output:
Yes


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
s = input()
if len(s)==a+b+1 and s[:a].isdigit() and s[a+1:].isdigit() and s[a]=='-':
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import re
a,b =[int(i) for i in input().split()]
content = input()

pattern = '[0-9]{3}-[0-9]{4}'

search_result = re.search(pattern, content)

if not(search_result) :
  print("No")
elif search_result.group() == content:
  print('Yes')
else:
  print("No")

Failing test case input:
6 4
269-6650

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
import re
a,b =[int(i) for i in input().split()]
content = input()

pattern = '[0-9]{' +str(a)+ '}-[0-9]{' +str(b)+ '}'

search_result = re.search(pattern, content)

if not(search_result) :
  print("No")
elif search_result.group() == content:
  print('Yes')
else:
  print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A, B = map(int, input().split())
S = input()

count = 0
S_list = []
for s in S:
    S_list.append(s)
    if s == '-':
        break
    else:
        count += 1

u_count = S_list.count('-')

if count == A and u_count == 1:
    print('Yes')
else:
    print('No')
    

Failing test case input:
0 -1
-+-

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
A, B = map(int, input().split())
S = input()

count = 0
for s in S:
    if s == '-':
        break
    else:
        count += 1

S_list = []
for s in S:
    S_list.append(s)

hy_count = S_list.count('-')

if count == A and hy_count == 1:
    print('Yes')
else:
    print('No')

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b = map(int,input().split())
s = input()
if s[a] == "-" and len(s) == a+b+1:
  print("Yes")
else:
  print("No")
  

Failing test case input:
1 1
---

Expected output:
No

Actual output:
Yes


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
s = input()
if s[a] == "-" and len(s) == a+b+1 and str.isdecimal(s[:a]) == True and str.isdecimal(s[a+1:]) == True:
    print("Yes")
else:
  print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A, B = map(int, input().split())
S = input()

count = 0
for s in S:
    if s == '-':
        break
    else:
        count += 1

if count == A:
    print('Yes')
else:
    print('No')

Failing test case input:
0 1
-,-

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
A, B = map(int, input().split())
S = input()

count = 0
for s in S:
    if s == '-':
        break
    else:
        count += 1

S_list = []
for s in S:
    S_list.append(s)

hy_count = S_list.count('-')

if count == A and hy_count == 1:
    print('Yes')
else:
    print('No')
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a, b = map(int,input().split())
s = input()
if s[a] == '-' and s[0:a] != '-' and s[a+1:] != '-':
    print('Yes')
else:
    print('No')

Failing test case input:
0 1
-,-

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a, b = map(int,input().split())
s = input()
n = s[:a] + s[a+1:]
print('Yes' if s[a]=='-' and n.isdigit() else 'No')

Problem: p03474
Buggy submission (PyPy3 (7.3.0), verdict: Wrong Answer):
a,b = map(int,input().split())
s = list(input())
n = len(s)
ans = "No"
for i in range(n):
  if s[i] == "-":
    if a == i:
      ans = "Yes"
if s.count("-") >= 1:
  ans = "No"
      
print(ans)



Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
s = list(input())
n = len(s)
ans = "No"
for i in range(n):
  if s[i] == "-":
    if a == i:
      ans = "Yes"
if s.count("-") > 1:
  ans = "No"
      
print(ans)

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a, b = map(int, input().split())
s = list(input())

flag1 = False
if s[a] == '-':
    flag1 = True

flag2 = False
if not '-' in s[:a - 1] and '-' in s[a + 1:]:
    flag2 = True
  
if flag1 and flag2:
    print('Yes')
else:
    print('No')


Failing test case input:
1 0
---

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a, b = map(int, input().split())
s = list(input())

flag1 = False
if s[a] == '-':
    flag1 = True

flag2 = False
if not '-' in s[:a - 1] and not '-' in s[a + 1:]:
    flag2 = True

if flag1 and flag2:
    print('Yes')
else:
    print('No')

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a, b = list(input().split())
s = input()

sl = s.split('-')
if len(sl) != 2:
    print('No')
elif ( sl[0].isdigit() and len(sl[0]) ) and ( sl[1].isdigit() and len(sl[1]) ):
   print('Yes')
else:
    print('No')

Failing test case input:
6 8
269-6650

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a, b = list(map(int, input().split()))
s = input()

sl = s.split('-')
if len(sl) != 2:
    print('No')
elif ( sl[0].isdecimal() and len(sl[0]) == a ) and ( sl[1].isdecimal() and len(sl[1]) == b):
   print('Yes')
else:
    print('No')

Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
a,b = map(int,input().split())
s = input()
print("Yes" if s[:a].isdigit() and s[a:].isdigit() else "No")

Failing test case input:
-1 1
57

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
s = input()
print("Yes" if s[:a].isdigit() and s[a+1:].isdigit() and s[a]=="-" else "No")
Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
import math
def py():
    print("Yes")
def pn():
    print("No")
def iin():
    x = int(input())
    return x

neko = 0
nya = 0
nuko = 0

a,b = map(int,input().split())
s = input()
for x in range(len(s)):
    if s[x] == '-':
        neko = x
if (a == neko)and(b == len(s)-1-neko):
    py()
else:
    pn()

Failing test case input:
0 1
27

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
import math
def py():
    print("Yes")
def pn():
    print("No")
def iin():
    x = int(input())
    return x

neko = 0
nya = 0
nuko = 0

a,b = map(int,input().split())
s = input()
for x in range(len(s)):
    if s[x] == '-':
        neko = x
        nya+=1
if nya != 1:
    pn()
elif (a == neko)and(b == len(s)-1-neko):
    py()
else:
    pn()

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A,B =map(int,input().split())
hih=0
num=1
S=str(input())
S= list(S)
for s in S:
    if s=="-":
        hih=num
    num+=1
if hih==A:
    print("Yes")
else:
    print("No")

Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):

A,B =map(int,input().split())
hih=0
num=1
test=1
S=str(input())
S= list(S)
for s in S:
    if num==A+1 and s=="-":
        hih=1
    if num!=A+1 and s=="-":
        test=0
        
    
    num+=1
if hih==1 and test==1:
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b=map(int,input().split())
s=input()
print("True") if s[:a].isdigit() and s[a]=='-' and s[a+1:a+b+1].isdigit() else print("No")

Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
True


Fixed submission (verdict: Accepted):
a,b=map(int,input().split())
s=input()
if s[:a].isdigit() and s[a]=='-' and s[a+1:a+b+1].isdigit():
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.8.2), verdict: Wrong Answer):


a,b=3, 4
s="269-6650"

ans="No"
if len(s)==a+b+1:
  if s[a]=="-":
    if s[0:a].isdigit() and s[b:len(s)].isdigit():
      ans="Yes"
    
print(ans)

Failing test case input:
-1 1
16443

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a,b=map(int,input().split())
s=input()

ans="No"

if s[a]=="-":
  if s[:a].isdigit() and s[a+1:].isdigit():
    ans="Yes"

print(ans)
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import re

def validate(a, b, s):
    pattern = "\\d{%d}-\\d{%d}"%(a, b)
    print(pattern)
    m = re.match(pattern, s)
    return m is not None



if __name__ == "__main__":
    a, b = map(int, input().split())
    s = input()
    if validate(a, b, s):
        print("Yes")
    else:
        print("No")

Failing test case input:
0 -1
.+,

Expected output:
No


Actual output:
\d{0}-\d{-1}
No


Fixed submission (verdict: Accepted):
import re

def validate(a, b, s):
    pattern = "\\d{%d}-\\d{%d}"%(a, b)
    
    m = re.match(pattern, s)
    return m is not None



if __name__ == "__main__":
    a, b = map(int, input().split())
    s = input()
    if validate(a, b, s):
        print("Yes")
    else:
        print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b = map(int,input().split())
s = input()
print(["No","Yes"][len(s[:a])==a and len(s[a+1:])==b and s.count("-")==1])

Failing test case input:
6 1
269-6650

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
s = input()
print("Yes" if s[a]=="-" and s.count("-")==1 else "No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b=map(int,input().split())
s=input()
print("Yes" if s.count("-")==1 else "No")

Failing test case input:
0 0
.-)

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a,b=map(int,input().split())
s=input()
print("Yes" if s.count("-")==1 and s[a]=="-" else "No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A,B =map(int,input().split())
hih=0
num=2
S=str(input())
S= list(S)
for s in S:
    if s=="-":
        hih=num
    num+=1
if hih==A:
    print("Yes")
else:
    print("No")

Failing test case input:
0 0
.+,

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):

A,B =map(int,input().split())
hih=0
num=1
test=1
S=str(input())
S= list(S)
for s in S:
    if num==A+1 and s=="-":
        hih=1
    if num!=A+1 and s=="-":
        test=0
        
    
    num+=1
if hih==1 and test==1:
    print("Yes")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A, B = map(int, input().split())
S = list(input().split('-'))
try:
    if len(S[0]) == A and len(S2[1]) == B:
        print('Yes')
    else:
        print('No')
except:
    print('No')


Failing test case input:
3 4
269-6650

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
A, B = map(int, input().split())
S = input()
if S.count('-') != 1:
    print('No')
else:
    S = list(S.split('-'))
    if len(S[0]) == A and len(S[1]) == B:
        print('Yes')
    else:
        print('No')
Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):





if __name__ == '__main__':
    import re

    A, B = list(map(int, input().split()))
    S = str(input())

    text = r'(\d{{0}})\-(\d{{1}})'.format(A, B)
    pattern = re.compile(text)
    result = pattern.search(S)

    if result:
        print("Yes")
    else:
        print("No")


Failing test case input:
6 8
269-6650

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):





if __name__ == '__main__':
    import re

    A, B = list(map(str, input().split()))
    S = str(input())

    text = r'\d{' + A + '}\-\d{' + B + '}'
    result = re.match(text, S)

    if result:
        print("Yes")
    else:
        print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a, b = map(int, input().split())
s = input()

for i in range(len(s)):
    if s[i] == '-' and i == a:
        print("Yes")
    elif s[i] == '-' and i  != a:
        print("No")

Failing test case input:
0 1
27

Expected output:
No


Actual output:

Fixed submission (verdict: Accepted):
a, b = map(int, input().split())
s = input()

if s.count('-') != 1:
    print("No")
else:
    for i in range(len(s)):
        if s[i] == '-' and i == a:
            print("Yes")
        elif s[i] == '-' and i  != a:
            print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a, b = map(int, input().split())
s = input()
print(s[a])
if(s[a] == "-"):
    try:
        int(s[:a])
        int(s[a + 1:])
        print("Yes")
    except:
        print("No")
else:
    print("No")

Failing test case input:
1 0
,--

Expected output:
No


Actual output:
-
No


Fixed submission (verdict: Accepted):
a, b = map(int, input().split())
s = input()
if(s[a] == "-"):
    try:
        int(s[:a])
        int(s[a + 1:])
        print("Yes")
    except:
        print("No")
else:
    print("No")

Problem: p03474
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
A, B = map(int, input().split())
S = input()

a = S[:A]
c = S[A]
b = S[A:]

try:
    a = int(a)
    b = int(b)
    if c == '-':
        print('yes')
    else:
        print('no')
except:
    print('no')

Failing test case input:
0 -1
),.

Expected output:
No


Actual output:
no


Fixed submission (verdict: Accepted):
A, B = map(int, input().split())
S = input()

a = S[:A]
c = S[A]
b = S[A:]

try:
    a = int(a)
    b = int(b)
    if c == '-':
        print('Yes')
    else:
        print('No')
except:
    print('No')