wuhudsm's blog

By wuhudsm, history, 5 months ago, In English

A: Short Query

Idea:Yugandhar_Master

solution
code(C++)

B: Minimum MEX

Idea:Yugandhar_Master

solution
code(C++)

C: Range Contradiction

Idea:Yugandhar_Master

solution
code(C++)

D: Eleven

Idea:Yugandhar_Master

solution
code(C++)

E: Not a Segment Tree

Idea:Yugandhar_Master

solution
code(C++)

F2: Award from Wuhudsm(Hard Version)

Idea:Yugandhar_Master

solution
code(C++)
  • Vote: I like it
  • +12
  • Vote: I do not like it

»
5 months ago, # |
Rev. 2   Vote: I like it 0 Vote: I do not like it

[Deleted]

»
5 months ago, # |
  Vote: I like it 0 Vote: I do not like it

For D, we can just handle the process until every 0 is flipped. The other part could be handled by flip each character in S then the process is same. For F1, I just did some optimization on my O(N^3) dp and it runs so fast. Just slightly less than 3s.

»
5 months ago, # |
  Vote: I like it 0 Vote: I do not like it

In F, could somebody explain how to use segment tree to maintain the maximum value of $$$dp2_{k,j - i+k}+d_{k,i}$$$?