You are not logged in. Please login at www.codechef.com to post your questions!

×

Gettin WA in DISHOWN

Pls help in letting me know what are the test cases on which my code fails in the practice(easy)DISHOWN. I have tried all possible test cases.. Pls help :( Here is my code https://www.codechef.com/viewsolution/8892158

asked 07 Dec '15, 15:25

mayank1995's gravatar image

1★mayank1995
713
accept rate: 0%


When you are checking this: else if(s[x-1]<s[y-1]) d.union(parent,x,y); x-1 th dish may already be taken by some other chef, so take the parent of x-1 and the parent of y-1. Have a look at my code if you want.

https://www.codechef.com/viewsolution/8900500

link

answered 07 Dec '15, 23:12

swetanjal's gravatar image

5★swetanjal
563
accept rate: 7%

edited 08 Dec '15, 00:07

toggle preview
Preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported
  • mathemetical formulas in Latex between $ symbol

Question tags:

×121
×66
×20

question asked: 07 Dec '15, 15:25

question was seen: 721 times

last updated: 08 Dec '15, 00:07