ICPC 2019 online round discussion

That’s even more unlikely than point 1.
I don’t think they will change selection criteria now.

Btw, Its kind of funny that no matter what CC always tend to screw up ICPC online rounds. (at least past 2 years) :joy: :rofl:

2 Likes

The number of merit based slots for Amritapuri were decreased because in case of all merit teams, they were being given less world final slots, while with a mixture of merit and college first, the number of world final slots were increased.

2 Likes

I don’t know how this works but we already have 3 sites which select on basis of colleges. Do each site has to keep college based selection to get more slots in world finals. Isn’t selection from all the sites together considered for word final slots ?

Can you please help me in the third question?
Logic: I sorted them as according to their speed then I checked if there are atleast three segments with same speed and are touching or intersecting.
Here is the link to my solution : [ImHwvJ - Online C++0x Compiler & Debugging Tool - Ideone.com ]

Alright. Can you suggest any testcase where my code would fail?
I tried some testcases but this code is giving correct ans.

Ur code doesn’t check 3 segments intersecting or touching i.e. A touches B, B touches C, C touches A. Ur code fails for following l,r values with same speed:-
1,7 - 2,4 - 5,6
Answer is YES

2 Likes

Ohh yes, got it.

easier implementation.

1 Like

Wow, nice approach :ok_hand:t2:

But it is giving “NO” for this case.
1
3
4 7 1
5 9 1
8 11 1
Shouldn’t the answer be YES, we can send 1st and 3rd one in same dir and 2nd one in other dir

The answer is yes indeed. You might have taken wrong input.

Do you mind sharing your code ? ( In case you have preserved it ) ?

Certainly!

Yes, easier. I didn’t use map earlier. Otherwise, result would be AC. But it’s fine. Can we resubmit that question in practice ?

There was problem with the IDE mode of submission. First of all, the file upload was not functioning properly.
Secondly, when we copy-pasted the code from our editor to the IDE, unless we ran it there and then submit, the previous code was being submitted everytime. This caused us 3 penalties in question 3.
Then we thought to click on our solution link and we noticed that our old code was being submitted everytime even when we were submitting our correct code.
Finally when we saw this, we ran our correct code on the IDE and submitted. Only then our updated code was submitted and we got an AC eventually.

Whereas the file upload as well as the IDE worked fine in the practice contest.

Please look into it @admin Had this issue not been there, we wouldn’t have got 3 penalties and we would have secured a rank under 500 and qualify for the Gwalior regionals (being 1st in our college). This is very very unfair! Codechef shouldn’t host ICPC anymore if you can’t even handle such an important contest every year.
It was our final year and lost the opportunity just because of CodeChef :frowning:

3 Likes

No think if you get a big segment of like 1 to 100. And have many small segments in it, for convinence lets take 3 segments, 1 us from 1 to 5 second is from 10 to 20 and third is from 50 to 90. They all have same speed. Then we can give the largest segment the velocity of -1*speed and rest of them the posirive velocity. They would never touch or intersect each other. This was the corner case.

P3:

bool isOverlap2(int x1,int x2,int y1,int y2){
    return (y1<=x2) && (x1<=y2);
}

bool isOverlap3(int x1,int x2,int y1,int y2,int z1,int z2){
    bool a=isOverlap2(x1,x2,y1,y2);
    bool b=isOverlap2(x1,x2,z1,z2);
    bool c=isOverlap2(y1,y2,z1,z2);
    return (a&&b&&c);
}

signed main(){
    int t;cin>>t;
    while(t--){
        int n;cin>>n;
        vector<pair<int,pii>> v(n);
        for(int i=0;i<n;i++){
            int x,y,val;cin>>x>>y>>val;
            v[i]={val,{x,y}};
        }
        int flg=0;
        for(int i=0;i<=n-3 && !flg;i++){
            for(int j=i+1;j<=n-2 && !flg;j++){
                if(v[i].first==v[j].first){
                    for(int k=j+1;k<=n-1 && !flg;k++){
                        if(v[k].first==v[j].first){
                            int x1=v[i].second.first;
                            int x2=v[i].second.second;
                            int y1=v[j].second.first;
                            int y2=v[j].second.second;
                            int z1=v[k].second.first;
                            int z2=v[k].second.second;
                            if(isOverlap3(x1,x2,y1,y2,z1,z2)){
                                flg=1;
                            }
                        }
                    }
                }
            }
        }
        if(flg){
            cout<<"NO\n";
        }else cout<<"YES\n";
    }
}
1 Like

I didn’t really get why everyone keeps on saying that deletion of SUMOR from problemset would be unfair to those who got AC.

  1. Dude, we get that you did spend time on it, and got AC. But there were others who spent more time on it, to first figure this greedy solution, and then they found a counter case (not everyone submits based on their intuition.), and since the number of submissions was really high they spent more time on it.
  2. Again dude, you submitted a wrong solution, that nohow explains, why you’re a better candidate for regionals than others, when you submit solutions without even proving (or trying) correctness, when it can cost you WA’s and lot more time, if your intuition was wrong.
7 Likes

First of all as i clearly mentioned in my post that my team did not submit SUMOR Problem, so what ever i wrote was from a neutral POV according to whatever seems unfair to me.

  • My only point for it being unfair to those who got AC is that had they got WA at the time of contest they could have come with a correct solution.
  • As i clearly mentioned i did not submit solution to it nor i am saying those who did without proving are better candidates for regionals. But it is widely seen for many of the medium level greedy problems that most of the submissions which are made whenever a medium greedy problem appears in a contest is based upon intuition and people do take the risk of getting WA as correctness of those solutions are often hard to prove and most of the submissions which are made for such problems are not proved first.
1 Like