hit023's blog

By hit023, history, 10 months ago, In English,

The problem (link) statement says clearly that the response from the system will be 3rd and the 4th meatiest meatball from the given 5 meatball indices. But in the example given, the 2nd and 3rd meatiest are being returned. What are we expected to do? Any clarification (from people who have solved the problem or otherwise) will be appreciated.

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

»
10 months ago, # |
  Vote: I like it -8 Vote: I do not like it

you got it wrong, In sample its given order or meatiness is 1<2<3<4<5<6 so among 1,2,3,4,5 obviously 3rd and 4th = (3,4) and among 1,2,4,5,6 3rd and 4th = (4,5). Here a<b means b is more meatier than a.

  • »
    »
    10 months ago, # ^ |
    Rev. 2   Vote: I like it 0 Vote: I do not like it

    Hi, So in 1 2 3 4 5
    5 is the first meatiest 4 is the second meatiest
    3 is the 3rd meatiest right?..

    Or is 1 the meatiest?

    • »
      »
      »
      10 months ago, # ^ |
        Vote: I like it -8 Vote: I do not like it

      Here higher the rank more the meatiness so 5 is 5th meatiest, follow this anology and everything will make sense

»
10 months ago, # |
  Vote: I like it -8 Vote: I do not like it

can anyone explain the problem https://www.codechef.com/DEC18B/problems/INTXOR ? am not understand the statement of this problem.

  • »
    »
    10 months ago, # ^ |
      Vote: I like it -8 Vote: I do not like it

    There are N hidden numbers lets say a1 a2 ... aN.
    Now you ask some queries in which you will give any 3 index and judge will return xor of numbers at those positions.Ex 1,4,5 then judge will return a1(xor)a4(xor)a5
    Your task is to find all hidden numbers using at most N queries.And some index i should not be appear more than 3 times in your all query.
    For example if you have asked queries like 1 2 3, 1 2 4, 1 2 5, then you cant ask 1 3 5.

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

    The statement is crystal clear if are asking for hint then again it will be your loss even in COMAS codechef have added explanation to decribe what they want to tell us. So please close this blog as all will ask for hint and spam the answer

»
10 months ago, # |
  Vote: I like it +4 Vote: I do not like it

There is a clear ambiguity in the problem statement and I faced the same issue.
But the correct answer will be achieved when you perceive the statement as 3rd and 2nd meatiest balls(in this order) are being returned as the answer.
You can see more clarifications on this link.

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

    can you explain the example test cases, how they decide the answer is 6 ?