skg
BAN USER
Comments (3)
Reputation 5
Page:
1
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
-1
of 1 vote
there are three cases to figure:
1. if month is 2(feb) then check for leap year.
2. if month is 12(dec) then check if it crosses 31st dec then new month will contain new year.
3. check same for 1(jan).
else in other cases use general method to count number of days in month and etc.
Comment hidden because of low score. Click to expand.
Page:
1
CareerCup is the world's biggest and best source for software engineering interview preparation. See all our resources.
none of them working correctly.
- skg March 10, 2012try for this input "abccaccba"
solution should be "b"
but they are showing wrong output