atcoder_official's blog

By atcoder_official, history, 18 months ago, In English

We will hold AtCoder Beginner Contest 409.

We are looking forward to your participation!

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

| Write comment?
»
18 months ago, hide # |
 
Vote: I like it -7 Vote: I do not like it

I'll keep my vote until the contest ends.

Wish I could upvote this contest.

»
18 months ago, hide # |
 
Vote: I like it +3 Vote: I do not like it

good luck!

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

4T!!! oh yeah!!!

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

I am surprised my solution for C worked. Lol !

»
18 months ago, hide # |
← Rev. 3  
Vote: I like it +1 Vote: I do not like it

E is much easier than regular Es, over 3000 people solved it! Maybe it's the most solved E in ABCs. But that caused a speedcoder for those solved E and couldn't solve F. I got 2239th for solving ABCDE (but I even got 2187th for solving ABCD in ABC403), too bad :(

upd: people who solved ABCDE can get a perf ranging from 1059(2734th) to 1529(1036th)...

»
18 months ago, hide # |
 
Vote: I like it +1 Vote: I do not like it

I'm a bit underwhelmed that Problem F practically forces us to use priority_queue, and set just keeps getting TLE'd

It may explain some TLE submission's reason

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

WTF using std::set in F fails while using std::priority_queue pass.

  • »
    »
    18 months ago, hide # ^ |
     
    Vote: I like it +1 Vote: I do not like it

    priority_queue is faster, what's the problem with it?

  • »
    »
    18 months ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    Bro can you please look into this code for E,I have tried to find it but couldn't I am trying to go from leaves to root, and computing cost each time Code and removing all dependencies of parent of every node before using it to compute cost

    • »
      »
      »
      18 months ago, hide # ^ |
       
      Vote: I like it 0 Vote: I do not like it

      Bro the cost of moving a particle upward equals to the cost of moving it downside. So you don't need that much logic

  • »
    »
    18 months ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    Although they have the same complexity order, but remember that set is based on tree, which may involve some rotation operations, in order to maintain the order, while priority_queue is based on heap, where we just move nodes along the path to the root.

    A more intuitive understanding may be that, it costs more if we want to obtain more information.

    As we only know the maximum element of the priority_queue, but we could get more information from set, for instance, lower_bound/iterator operations, I think one should forgive that set costs more :D

  • »
    »
    18 months ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    same

»
18 months ago, hide # |
 
Vote: I like it +22 Vote: I do not like it

F has a good idea, but the time limit is too strict. I used map+vector at first so I got two TLE submissions. That ruined my Performance :(

»
18 months ago, hide # |
 
Vote: I like it +5 Vote: I do not like it

F took a lot of time to implement. Could not submit it in time.

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

G makes me want to kill myself.

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

Why my F wrong anwer on the last one.

Code

  • »
    »
    18 months ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    The Manhattan distance between two points can be greater than mn, so it's better to use a value like inf = 2e9 + 10

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

in F, i'm getting TLE on 3 cases. Can somebody help me optimize this? The idea is very cool btw. feeling overwhelmed with my solution.

Link

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

Weak testcases in D: My submission doesn't handle already sorted string input with length greater than 1, still got accepted.

My Submission

Edit: Ignore please, the substring length can be 1, i don't know why i was assuming otherwise.