Loading...
「ツール」は右上に移動しました。
利用したサーバー: wtserver1
68いいね 2,208 views回再生

Sweep Line pt.1 (Maths for CP series)

I have covered questions of Sweep like Subarray sum, KQUERY, DQUERY

Notes:
Main idea behind sweep is that we fix one pointer or dimension and update remaining points according to that. Also the updation process is monotonous that is we only add or remove only once from our data structure that is convenient to us.


Links from the video:
SPOJ KQUERY : https://www.spoj.com/problems/KQUERY/
KQUERY code: http://p.ip.fi/uZAm
SPOJ DQUERY : https://www.spoj.com/problems/DQUERY/
DQUERY code: http://p.ip.fi/LEZB

Practice Problems :

https://www.codechef.com/problems/PAI...
https://www.codechef.com/problems/LAZER
https://www.hackerrank.com/contests/h...

コメント