in the sorted array, if suppose fr[i].start==fr[i+1].start then u only
consider a cut at f[i+1] (that means ith fruit is also cut with the (i+1)th
fruit.
Thus u keep on incrementing the sorted array until u find sm j s.t.
f[j].start!=f[j+1].start
Then u check for the condition :
did u see the comment that nikhil made
herehttp://stackoverflow.com/questions/14545917/spoj-juice-extractor-wrong-ans
?
On Thu, Feb 21, 2013 at 1:00 AM, marti amritsa...@gmail.com wrote:
? ^^
On Thursday, January 24, 2013 1:35:38 PM UTC+5:30, emmy wrote:
please help me with the
matches are already sliced.and this u can do by moving
incrementally from 0 to mth matches.
On Mon, Jan 28, 2013 at 1:43 PM, foram lakhani foramlakh...@gmail.comwrote:
by match u mean that number of fruits that overlap with i th fruit but
are not sliced before time i.
which means we have
until the cut of j.
Hope this will help.
Thanks
On Thu, Jan 24, 2013 at 10:18 PM, foram lakhani foramlakh...@gmail.comwrote:
Thanx for the reply but I didnt get you. What does dp[i] represent ?
On Thu, Jan 24, 2013 at 9:50 PM, sunny sharadsin...@gmail.com wrote:
take a structure or pair
Thanx for the reply but I didnt get you. What does dp[i] represent ?
On Thu, Jan 24, 2013 at 9:50 PM, sunny sharadsin...@gmail.com wrote:
take a structure or pair of start time and finish time and then sort the
the structure you know the comparator function the for each for each dp[i]
select