====Псевдокод====
'''func''' findMinCycleBinarySearch('''int''' l, '''int''' r)
m = (l + r) / 2
'''for''' e '''in''' edges
e.weight -= m
'''while''' l > r - 1
'''if''' <tex>\exists</tex>C : M(C) < 0 <!--- cho-t xz za4em C: mb exists? eee ugadala)0))---> findMinCycleBinarySearch (l, m) '''else''' findMinCycleBinarySearch (m, r)
===Продвинутый алгоритм===