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

Автор Philosophi, история, 3 месяца назад, По-английски

https://mirror.codeforces.com/contest/1726/submission/365331041 Can anyone tell me where did i do wrong in this solution ? thanks

Update: My answer in the first test can be drawn in a pic like this

If we remove blue we get 2 connected components, if we remove red we get 1 connected component. So in total we get 3, which is the same with the answer. Was my understanding wrong somewhere?

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

»
3 месяца назад, скрыть # |
 
Проголосовать: нравится -11 Проголосовать: не нравится

You should run the sample test before submitting it...

»
3 месяца назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Auto comment: topic has been updated by Philosophi (previous revision, new revision, compare).

»
3 месяца назад, скрыть # |
 
Проголосовать: нравится +6 Проголосовать: не нравится

afaik you understood the problem right, but on the submission page your code responds to sample 1 with 1110010 and the jury answer 1110001

your answer would mark edges the following edges red: (1, 2) (2, 3) (3, 4) (1, 3) which doesn't match your drawing. The jury's answer matches your drawing with red and blue swapped though.