Svagt matchande rim för bellman-ford-algorithmus