Solution to 452B -Div 2

Revision en1, by reluctantcoder, 2017-12-19 17:35:28

I had written the entire 4 years of non-leap,leap, non-leap,non-leap as a string and also took the input as a string. the integer input is redundant. I used library function 'strstr' to compare the two inputs. By bruteforce, the answer must be 'yes' if their exists a substring like that otherwise a no. But it gives yes for all. can anyone tell me where is the error? I know the solution using the array. but i wanted to try this one out. Thanks in advance. This is a link to my solution http://codeforces.com/contest/899/submission/33410715

Tags 452b

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en1 English reluctantcoder 2017-12-19 17:35:28 568 Initial revision (published)