Submission #635893

#TimeUsernameProblemLanguageResultExecution timeMemory
635893karolb2011Dango Maker (JOI18_dango_maker)Pypy 3
13 / 100
44 ms18360 KiB
n,m=list(map(int,input().split())) s=[] for i in range(n): s.append(list(input())) c=0 for i in range(n): for j in range(m-2): if s[i][j]=="R" and s[i][j+1]=="G" and s[i][j+2]=="W": c+=1 s[i][j]="" s[i][j+1]="" s[i][j+2]="" for i in range(n-2): for j in range(m): if s[i][j]=="R" and s[i+1][j]=="G" and s[i+2][j]=="W": c+=1 s[i][j]="" s[i+1][j]="" s[i+2][j]="" print(c)
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...