思考题 for stupid myself

# A well-known task

Given N segments

Now you want to choose some segments

means the number of integers in the set

## Example

**Input**

{[1,5],w=3}

{[2,4],w=5}

{[3,5],w=1}

**Output**

**Explain**

choose 1 ->

choose 2 ->

choose 3 ->

choose 1,2 ->

choose 1,3 ->

choose 2,3 ->

choose 1,2,3 ->

## Constriants

Subtask 1(10%):

Subtask 2(20%):

Subtask 3(30%):

Subtask 4(40%):

The author can get 60%(30%)

**Orange boy will get AC quickly!**

# Slow (or Maybe Wrong) Solution By Weak XGN

Sort the segments by L. Then for each L we choose all segments with

Time Complexity is

**Proof Required**