Damon's blog

By Damon, 4 years ago, In English,

Hi, Round #288 was Div. 1 and Div. 2 yesterday.

What happened ? Now I see it's a Div .2 Only contest !

Is this a mistake ? Or plan changed ?

Read more »

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

By Damon, 4 years ago, In English,

Where is Sereja ? Why there isn't any other contest by Sereja ?

btw, we are waiting for you.

Read more »

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

By Damon, 5 years ago, In English,

Hi, bro !

I was trying to solve problem 126C - E-reader Display !

In this problem n is at most 2000, and my algorithm was O(n*n*log n).

getting input with cin : 5857002

getting input with scanf : 5858216

But my code got TLE , and I can't find it reason.

If you know it, please tell me !

Read more »

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

By Damon, 5 years ago, In English,

Hi.

4th Round of COCI contests take places at this time.

Contest site.

Note: You can discuss problems here, after contest end.

Update: Resault.

Winners

  1. fagu
  2. kennethsnow
  3. Xellos

Read more »

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

By Damon, 6 years ago, In English,

Hi !

I am trying to answer problem 155 at ACM.SGU.RU site .

Cartesian Tree

My algortihm is sort by a[i] elements , then create a BST by k[i] elements.

I know my algorithm in worse case is O(n^2) and n can be 50000 ! So my answer get TLE .

What can I do for this problem ? Is my algorithm wrong or can be optimize ?

Here is My Code

Read more »

 
 
 
 

By Damon, 6 years ago, In English,

Hi :)

In recent Codeforces contests , we see many problem with "Geometry" tag ! so I decide to learn Geometry algorithms and formula !

What must I do ?

Read more »

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

By Damon, 6 years ago, In English,

Hi :) We have two string with same size ! ( n = strings.size() )

I want an algorithm with O(n.lg n) , to find LCS of this strings .

What is best Order of this problem ? I can find it with O(n^2) by using dp !

sry 4 my bad English! :|

Read more »

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