# | User | Rating |
---|---|---|
1 | tourist | 3985 |
2 | jiangly | 3814 |
3 | jqdai0815 | 3682 |
4 | Benq | 3529 |
5 | orzdevinwang | 3526 |
6 | ksun48 | 3517 |
7 | Radewoosh | 3410 |
8 | hos.lyric | 3399 |
9 | ecnerwala | 3392 |
9 | Um_nik | 3392 |
# | User | Contrib. |
---|---|---|
1 | cry | 169 |
2 | maomao90 | 162 |
2 | Um_nik | 162 |
4 | atcoder_official | 161 |
5 | djm03178 | 158 |
6 | -is-this-fft- | 157 |
7 | adamant | 155 |
8 | awoo | 154 |
8 | Dominater069 | 154 |
10 | luogu_official | 150 |
Name |
---|
Thanks, seems like I'm going for my first SRM ever :)
Good luck)
It conflicts with Codingame challenge
Also with first 1/8 fifa game [Brazil — Chile] Sad. hadn't decide which one I will choose.
Can someone explain why in 500 we get a huge negative score in example 1 using a self loop from a final vertex (vertex 1), but in example 3 we are not allowed to go back and forth between vertices 1 and 2 to get a huge negative score?
Thanks!
The graph is directed.
How was Div2 1000 problem to be solved?
My fail on 900 this time was quite unusual: the whole problem can be siplified to counting sum of squares of integers coprime to and (the answer's that times a2 + b2), but for some mysterious reason, I decided to count the sum of squares of non-divisors. Not to mention I didn't notice that and though that I'm only failing on the last sample due to some hidden overflow, because what else could cause me to pass the other large sample? (Of course, it's the fact that is a power of 2 in all samples except the last one and the one where the answer's trivially 0.) Boop.
In the end, this reduction's easily solvable by Google Search Algorithm...
For problem 250 div 2 I have solved it with a really fast algorithm but it's status is "challenge succeeded" . I don't know what it means ?
Your solution may have passed the given test cases, but it was not correct.
The person who hacked(challenged) your solution found a test case, where your algo gave the wrong output
How was Div1 600 problem solved?
dp[a][b][c] — answer for way from a to b with c charges.
if c==0 then answer is shortest path (floyd helps)
if c is even then for some vertex i answer is dp[a][i][c/2]+dp[i][b][c/2]. for all such i we take best.
if c is odd then instead of vertex we choose edge (i,j) and answer is dp[a][i][c/2] + dp[j][b][c/2] — weight(i,j).
c charges will be between 0 and 1,000,000,000, inclusive so how can it be the third dimension ??
look carefully: charges always divided by 2, so total number of states is O(n2log(Charges))
Got it.Thnxz.
I can't get the point of (even & odd) how & why it work ?
thanks
Think about the shortest path from u to v with c charges (c is even). Since you do charges one by one, there will unequivocably be a middle node m such that you do c / 2 charges from u to m and c / 2 charges from m to v. That's why the DP works.