justHusam's blog

By justHusam, 8 years ago, In English

Hello Codeforces,

I would like to invite you all to participate in the 2018 JUST Collegiate Programming Contest. The contest was originally held on 31st of March, and it will launch in Codeforces Gym on Saturday 28 July 2018 10:00 UTC.

The problems were prepared by justHusam, Lvitsa, and Roze.

Thanks to Dark, Ptrq, and AbedAbuhijleh for testing the problem set.

The duration of the contest is 4 hours, and the registration will be open 6 hours before the start of the contest.

Good luck to everyone, and I wish you all accepted solutions.

UPD: Registration is currently open.

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

| Write comment?
»
8 years ago, hide # |
 
Vote: I like it +14 Vote: I do not like it

The difficulity of problems is Div.3 or Div.2???

»
8 years ago, hide # |
 
Vote: I like it +14 Vote: I do not like it

How to solve problem G-Hard Equation ?

»
8 years ago, hide # |
 
Vote: I like it +3 Vote: I do not like it

Is there an editorial?

»
8 years ago, hide # |
Rev. 3  
Vote: I like it 0 Vote: I do not like it

how to solve problem E. Maximum Sum ?

  • »
    »
    8 years ago, hide # ^ |
    Rev. 2  
    Vote: I like it +4 Vote: I do not like it

    You can solve it using dynamic programming. Think of it as if you want to calculate the answer of the of row i, then you only care about which cells you have chosen in the row i - 1. Or you can think if you want to choose cell (x, y), then you only need to check if you have chosen cells (x, y - 1), (x - 1, y - 1), (x - 1, y), and (x - 1, y + 1).

»
8 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

What testcase was added to B after the contest?

  • »
    »
    8 years ago, hide # ^ |
     
    Vote: I like it +2 Vote: I do not like it

    A contestant sent me a message with a test case that can break some accepted solutions after the contest has ended, so I updated the test cases. I prefer not to tell you about the test case so you can discover your mistake by yourself =D.

»
8 years ago, hide # |
Rev. 2  
Vote: I like it 0 Vote: I do not like it

how to solve problem A?

»
8 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

what is the solution for I circles?? its giving tle in test 2

»
8 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

any hint for C. intersections??

»
8 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Can the administrator please open the solution of all users??

»
8 years ago, hide # |
 
Vote: I like it +3 Vote: I do not like it

There are some greedy solutions that do pass on problem B. Check this testcase:

1
4
2 5 10 14
M M F F

Solution is 2.

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

    In the question it is given that all triplets are co-primes but 2,10 and 14 are not co-primes.

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

      Right sorry but look at this case:

      1
      4
      10 21 55 6
      M M F F
      

      Solution is also 2 (pair 10 with 55 and 21 with 6), but wrong greedys will pair 10 with 6, and the 21 can't be paired with 55.

      Some codes that fail this testcase:

      code 1

      code 2

      code 3

      code 4

»
8 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

https://paste.ubuntu.com/p/77VbmCM8Tg/ can someone say what is wrong with my code? it's the solution for the k problem.

»
7 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

How to solve C intersection?