#D11788. Help the Princess!
Help the Princess!
Help the Princess!
Example
Input
2 4 %.@$ ..$$
Output
Yes
inputFormat
Input
2 4 %.@$ ..$$
outputFormat
Output
Yes
样例
2 4
%.@\$
..\$\$
Yes
Example
Input
2 4 %.@$ ..$$
Output
Yes
Input
2 4 %.@$ ..$$
Output
Yes
2 4
%.@\$
..\$\$
Yes
By signing up a OpenJudge universal account, you can submit code and join discussions in all online judging services provided by us.