I was trying to solve this problem using the palindromic tree. But I couldn't. Can someone help me?

# | User | Rating |
---|---|---|

1 | tourist | 3707 |

2 | Benq | 3672 |

3 | ksun48 | 3575 |

4 | Radewoosh | 3562 |

5 | Miracle03 | 3480 |

6 | maroonrk | 3406 |

7 | ecnerwala | 3400 |

8 | peehs_moorhsum | 3384 |

9 | sunset | 3338 |

10 | Um_nik | 3320 |

# | User | Contrib. |
---|---|---|

1 | 1-gon | 208 |

2 | Um_nik | 197 |

3 | YouKn0wWho | 192 |

4 | Errichto | 182 |

5 | sus | 181 |

6 | awoo | 180 |

7 | tourist | 175 |

8 | -is-this-fft- | 171 |

8 | SecondThread | 171 |

10 | Ashishgup | 170 |

I was trying to solve this problem using the palindromic tree. But I couldn't. Can someone help me?

**maximum bipartite matching** using bfs? Here is the dfs implementation of **maximum bipartite matching** using Ford Fulkerson algorithm for maximum flow.

**EDIT**: I used set in place of array to store weight. So, there should not be any case of overflow.But still getting RE with code.

Codeforces (c) Copyright 2010-2021 Mike Mirzayanov

The only programming contests Web 2.0 platform

Server time: Oct/25/2021 22:42:51 (i2).

Desktop version, switch to mobile version.

Supported by

User lists

Name |
---|