Блог пользователя mahesh_2002

Автор mahesh_2002, история, 4 года назад, По-английски

Experience the Competitive Programming Competition, for all participants of all levels of expertise. This event ensures that even an absolute beginner is able to solve something. So Get your Hands Dirty.

Compete against other coders and solve the questions prepared by the geekiest coders of IIT Hyderabad.

Date and Time: March 14th, 1500-1800 IST
Contest Link: Hackerrank Proquest
Registration Form: Details Form

You will have five problems and three hours to solve them. The problems are a good mix for all difficulty levels, from grandmasters to pupils. We have some hard problems, and some very easy too, and everything in between.

The results and prizes will appear on the contest leaderboard.

It's open for all. We hope you'll enjoy the competition.

  • Проголосовать: нравится
  • +9
  • Проголосовать: не нравится

»
4 года назад, # |
Rev. 2   Проголосовать: нравится 0 Проголосовать: не нравится

Decent problems! Enjoyed solving them.

»
4 года назад, # |
  Проголосовать: нравится +3 Проголосовать: не нравится

I wasn't able to see this in time. If possible, can the contest announcements be added to the blog a little earlier. I would surely see try the problems but won't be able to participate :)

»
4 года назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Will there be an editorial?

  • »
    »
    4 года назад, # ^ |
    Rev. 2   Проголосовать: нравится +14 Проголосовать: не нравится

    Long Year

    Store the number of days in each month in an array. Update february based on whether given year was leap or not. Check $$$1 \leq month \leq 12$$$ and date is valid for that month. Then it's just taking sum of number of days in months before current month, and the number of days in current month.

    Virus transmission

    Each person represent a circular region. Two regions overlap if distance between centres $$$\leq$$$ sum of radius of both circles. For each infected person, mark all persons as infected (in a boolean array) whose region intersects with any initially infected person.

    Clever Criminals

    We need number of houses visited odd number of times. House $$$x$$$ is visited only by $$$f(i)-1$$$ criminals (one less, since there's no thief stealing from consecutive houses, representing factor $$$1$$$), where $$$f(i)$$$ is the number of divisors. $$$M \geq N$$$ is important, since it means all divisors upto $$$N$$$ are tried.

    Hence, only houses visited even number of times are houses numbered with value $$$x$$$ where $$$x$$$ is a perfect square. This count can be counted naively in $$$O(\sqrt{N})$$$ and subtracted from $$$N-1$$$ House numbered $$$0$$$ is handled separately.

    Vaccine-Distribution

    Edges of graph forms connected components. All edges in a component get vaccination from the vertex providing vaccine at minimum cost within current component. It can be easily simulated using Disjoint Set Union.

    Vaccine Time

    Only when there are cyclic dependencies, that we need to merge them. Hence, for the given Directed dependency graph, build Strongly connected components, merge them. Resulting graph would be a DAG, run DP on this DAG to find minimum time at which ingredient at node x would be ready for all nodes $$$1 \leq x \leq N$$$ of original graph.

    Now we can sort these times and run binary search. It's easy to prove no dependency is ignored here.

    Let's Go Pawri !!

    This problem is classical TwoSAT where each type of condition represent one (or more) implications, and we need to check if TwoSAT can be satisfied.

    • condition 1 u v: !u => v, !v => u
    • condition 2 u v: u => !v, v => !u
    • condition 3 u v: u <=> v, !u <=> !v
    • condition 4 u v: !v => !u

    Read more on 2-SAT here

»
4 года назад, # |
  Проголосовать: нравится +24 Проголосовать: не нравится

Are there any updates regarding winners and prize distribution?

  • »
    »
    4 года назад, # ^ |
      Проголосовать: нравится -8 Проголосовать: не нравится

    The Winners will be announced on our Instagram page this Friday. Elan & nVision Instagram

    The details for the prizes for winners will be emailed or collected via Whatsapp within Thursday. Thank you all for participating in our contest.