The count of pattern
All submissions for this problem are available.
You are given two binary patterns. A binary pattern contains only 2 letters. You have to find the number of times the first binary pattern occurs in the second binary pattern
The first line of input contains 4 space separated integers, a,b,c,d.
a,b are respectively the rows and columns in the pattern.
c,d are respectively the rows and columns in the second pattern.
The output contains a single integer, the number of times the first pattern occurs in the second pattern.
1 <= a,b,c,d <=2000
4 4 10 10
|Time Limit:||- 1 sec|
|Source Limit:||50000 Bytes|
|Languages:||C, CPP14, JAVA, PYTH, PYTH 3.5, PYPY, CS2, PAS fpc, PAS gpc, RUBY, PHP, GO, NODEJS, HASK, SCALA, D, PERL, FORT, WSPC, ADA, CAML, ICK, BF, ASM, CLPS, PRLG, ICON, SCM qobi, PIKE, ST, NICE, LUA, BASH, NEM, LISP sbcl, LISP clisp, SCM guile, JS, ERL, TCL, PERL6, TEXT, SCM chicken, CLOJ, FS|
Fetching successful submissions
If you are still having problems, see a sample solution here.