Need a neat implementation of Min Cost-Max Flow algorithm as I am not able to understand e-maxx.ru . And my code is too buggy to debug. Any help would be appreciated.

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

1 | tourist | 3496 |

2 | W4yneb0t | 3218 |

3 | TakanashiRikka | 3178 |

4 | Petr | 3173 |

5 | moejy0viiiiiv | 3158 |

6 | LHiC | 3113 |

7 | izrak | 3109 |

8 | anta | 3106 |

9 | ershov.stanislav | 3105 |

10 | cubelover | 3071 |

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

1 | rng_58 | 178 |

2 | csacademy | 171 |

2 | tourist | 171 |

4 | Petr | 162 |

5 | Swistakk | 161 |

6 | Errichto | 156 |

7 | Zlobober | 150 |

8 | matthew99 | 145 |

9 | Endagorion | 142 |

10 | zscoder | 135 |

Need a neat implementation of Min Cost-Max Flow algorithm as I am not able to understand e-maxx.ru . And my code is too buggy to debug. Any help would be appreciated.

↑

↓

Codeforces (c) Copyright 2010-2017 Mike Mirzayanov

The only programming contests Web 2.0 platform

Server time: Oct/17/2017 02:48:28 (c2).

Desktop version, switch to mobile version.

User lists

Name |
---|

Hello! In this notebook has the implementation that I usually use, I hope it helps :)

https://github.com/Gabriel123Duarte/maratona-final/blob/master/Notebook/100%5Eo.pdf

Nice code bro.

This looks your '-'

First of all thanks for the pdf. Is there any Translated version of the above

Sorry, this pdf only has the version with the comments in portuguese :/

I hope this help you

http://ideone.com/jQqO6I

I know you got some codes already, but I thought mine could be helpful, too. Code, which is actually a solution to this problem.

hi thanks for the code can you also tell me the running time of code

I am sorry but I don't remember which article I learnt this from and I can't calculate the complexity myself. I only remember that for the assignment problem it works in

O(N^{3}*logN). If you actually meantrunning time, it's around 250 ms.i have seen implementation of mcmf with dijkstra, spfa and bellman ford. and most of them use spfa. why dijkstra is not used much despite having better complexity??