Comments
On MikeMirzayanovNew Year Gifts 2019!, 7 years ago
0

I think there's a bug in submission status the "who" column is still using my old handle instead of current handle

+1

I also confused with the editorial so I'm writing this so anyone can help me to clear the idea.

let's say you have 10 people and the input:

10

7 7 7 7 7 7 8 8 9 9

person[0] = There are 7 people with different hat other than me

person[1] = There are 7 people with different hat other than me

person[2] = There are 7 people with different hat other than me

person[3] = There are 7 people with different hat other than me

person[4] = There are 7 people with different hat other than me

person[5] = There are 7 people with different hat other than me

person[6] = There are 8 people with different hat other than me

person[7] = There are 8 people with different hat other than me

person[8] = There are 9 people with different hat other than me

person[9] = There are 9 people with different hat other than me

Step:

  • The easiest thing to realize is maybe person 8 & 9 is wearing the same hat, because they belong to the same group (a group that consists of people whom the hat is different with 9 people)

Our current answer:

X X X X X X X X 1 1

(X = don't know yet, but can be assured that it's not 1)

  • Then, we can help person 7 & 6 to know their hat since they also belong to the same group,

Our current answer:

X X X X X X 2 2 1 1 (Observe that person 7 & 6 using different hat, not 1, not X)

  • For the final step, we can do the same thing except we can't. Person 0 told us that there are 7 people which differs than him but if we mark all the X into 3, then there will be only 4 (person 6-9). But we can divide X into P/Q part such that P = number of people which told you they know A people with different hats, and Q = N — A, in this case, P = 6, Q = 3 so X will be divided into 2 parts

Our current answer:

3 3 3 4 4 4 2 2 1 1

The editorial state that P must be divisible by Q because if it's not it'll add more difference than what's needed, (6/3 -> 3 Red 3 Blue, 2 different hats | 7/3 -> 3 Red 3 Blue 1 Green, 3 different hats) (CMIIW). It's not a mathematical proof but it's based on my intuition, I welcome any suggestions!

On ErrichtoStream, 8 years ago
0

I still prefer youtube because not everyone can't watch live, or twitch has such feature that allows the user to playback the stream?

For problem A, why the accepted output of input '100' is '100', shouldn't it be '10'? (Because first we meet 1 and then terminate of first digit with 0 and then we meet 0, thus the output is 10) sorry for my bad english