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

×

[closed] Getting SIGSEGV in treap

I am trying to solve https://www.codechef.com/problems/CHEFDTRE. This is my first attempt at treap and I chose this problem as it seemed simple for beginner. But I am getting SIGSEGV in all cases. It runs fine on my computer. I am unable to find my mistake. Please help.

My code : https://www.codechef.com/viewsolution/8566926

I am following e-maxx.ru for the concept.

asked 17 Oct '15, 17:26

dragonemperor's gravatar image

3★dragonemperor
89321135
accept rate: 10%

closed 17 Oct '15, 18:32

The question has been closed for the following reason "Other" by dragonemperor 17 Oct '15, 18:32


I found the problem. I needed to update size of subtree at a lot of places. I don't know why, but I am sure I can figure it out on my own :)

link

answered 17 Oct '15, 18:31

dragonemperor's gravatar image

3★dragonemperor
89321135
accept rate: 10%

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:

×278
×57

question asked: 17 Oct '15, 17:26

question was seen: 640 times

last updated: 17 Oct '15, 18:32