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

×

Difference in the approach

I tried solving this using union find algorithm.

I got TLE in one and AC in second approach. I made only one line difference between the two and both are giving correct answer on my laptop. Can anyone tell me why this happened?

TLE

AC

asked 25 Feb '15, 18:20

dragonemperor's gravatar image

3★dragonemperor
89321135
accept rate: 10%

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:

×729

question asked: 25 Feb '15, 18:20

question was seen: 261 times

last updated: 25 Feb '15, 18:20