aopo's blog

By aopo, history, 2 months ago, In English

The official editorial of the Half Sequence says

This
Reason they give

But, what is the proof behind it? I mean what is the intution behind saying this? Can someone give a formal proof for it.

Read more »

 
 
 
 
  • Vote: I like it
  • +11
  • Vote: I do not like it

By aopo, history, 4 months ago, In English

Hello connections!

Recently i tried my hands on this problem. I solved it using segment tree and fenwick tree but i don't know how to solve it using LIS concept. It would be very nice if some of you can share your approach for solving this.

Here is what i think regarding this!

We maintain a multiset and go on inserting elements from left to right adding elements one by one , finding the upper_bound of ai and removing it if its exists and then doing ans=max(ans,*st.rbegin()) if the size of my multiset is bigger than l.But this is giving me WA.I don't know where am i going wrong.It would be very helpful if someone can point out my mistake.

Link to Problem

Read more »

 
 
 
 
  • Vote: I like it
  • 0
  • Vote: I do not like it

By aopo, history, 7 months ago, In English

Hello guys, can someone help me in understanding the solution to this problem. I read the editorila several times yet i can't get it.I don't know why is it written so "Let's shorthand this with minNumber(colorCount, number[colorCount])." Can someone share his ideas or any approach for solving this problem. I bet this is one of the most interesting problem on ad-hoc,greedy!

Read more »

 
 
 
 
  • Vote: I like it
  • -4
  • Vote: I do not like it