Блог пользователя utkarsh_108

Автор utkarsh_108, история, 8 месяцев назад, По-английски

The below article is an attempt to create a good starting point for people who practice some good DSU problems

you read the Nice blog by kartik8800 DSU Blog here you tell basics to advanced about DSU

below code is written by striver you can take reference from his YT channel TAKE U FORWARD

striver_79

standard DSU


#### PROBLEM 1

1 -> This Problem Based how we can use DSU beautifully by sorting the edges of the graph

1213G - Запросы на пути

Hint 1
Hint 2
DSU code

Check my submission


#### PROBLEM 2

2 -> This Problem is easy side of DSU to make the network connected

25D - Дороги не только в Берляндии

Hint 1
DSU code

Check my submission


#### PROBLEM 3

3 -> you have to make forest by adding edges by making two DSU

1559D1 - Mocha и Diana (простая версия)

Hint 1
DSU code

Check my submission


#### PROBLEM 4

4 -> This Problem Based how we can minimise the or of the no by making highest bit to Zero

1624G - Дерево минимального ора

Hint 1
DSU code

Check my submission


#### PROBLEM 5

5 -> This Problem Based how we can use DSU to connect the edges from edge weight form low to high

1468J - Road Reform

Hint 1
DSU code

Check my submission

this is good level 5 problem enough to Grasp the concepts if you want to try more prblem try this Codeforces DSU Problems

ALL THE BEST FOR YOUR CODING JOURNEY :)

  • Проголосовать: нравится
  • +2
  • Проголосовать: не нравится

»
8 месяцев назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Auto comment: topic has been updated by utkarsh_108 (previous revision, new revision, compare).

»
8 месяцев назад, # |
Rev. 2   Проголосовать: нравится +1 Проголосовать: не нравится

Here are two other DSU problems

https://atcoder.jp/contests/abc335/tasks/abc335_e

https://codeforces.me/problemset/problem/1914/G1

They introduce a technique commonly done with DSU, that is:

Spoiler