They announced this on FB page- The solutions are visible until INOI I guess.
Lets say our array is {1,2,6].
Now-
upper_bound(5)=lower_bound(5)=6;
If array is {1,2,5,6}.
Upper_bound(5)=6, lower_bound(5)=5.
Upper bound = return element >x, lower bound = return element >=x;
Upper bound = return smallest element >x, lower bound = return smallest element >=x;
And also it works only if the array is sorted in ascending order.
I assume he at least know and has read through the basics and just needs an example illustrating them.
thanks for answering and it helped my solution finally got accepted with 100pts.
Reported the issue. Thank you.
Reported the issue. Thank you.
Hi, Now I think that there’s some issue with the question as when I copy pasted the official solution and submitted, it got TLE as well. I am doing this to complete my A2OJ ladder, is there any other way I can get around this?
You are welcome. 
If you get any update in future please post.
Your question has been updated. Its under title “Please help me in CHEFSIGN”. Please refer there henceforth. 
Once my exams get over, I definitely will (if the Q isnt answered). Just remind me.
Can’t even ask a question independently… sigh Where are you reputation points?
This editorial will help you.
Link : Unofficial editorial December long challenge - editorial - CodeChef Discuss
This question has been answered multiple times.Please do a search before asking the question or ranting on the system. Multiple questions on same thing just degrade the forum quality.
Notice that there are only 2 patterns of cakes possible. Like, if cake is 3x3 matrix, then possible configurations are-
RGR
GRG
RGR
and
GRG
RGR
GRG
Just find which configuration gives minimum cost.
Thanks alot got it!
Your code fails here-
Input
1
5
10000
Your output
2
Expected Output
3
Thanx alot @vijju123, you helped me alot. btw i had made an error like ‘0’ (char)instead of 0(int). and also i didnt prepare for testcase i string was just 1. Thanks a ton! You have helped me alot :). If You are on codefights add me name- llgokull l==‘el’ not 1(one) 
Please google these type of questions.
Consider this TC:
2
aa
aa
Expected o/p: aa
Your code gives: Draw
Hope this helps. 