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

×

Regarding HORRIBLE-SPOJ

Implemented Segment tree for finding query and updation. Getting TLE.How can I optimize to get AC?

HORRIBLE-SPOJ

My Code:

asked 25 Mar '15, 19:04

ab13123002's gravatar image

5★ab13123002
4126
accept rate: 8%


Lazy propagation.. Google it .. Lazy propagation is an effective way of range update range query with complexit(log n)

link

answered 25 Mar '15, 19:24

anh1l1ator's gravatar image

6★anh1l1ator
142618
accept rate: 11%

edited 25 Mar '15, 19:25

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:

×1,755
×720

question asked: 25 Mar '15, 19:04

question was seen: 684 times

last updated: 25 Mar '15, 19:25