1 votes 1 votes Can someone work this out? Algorithms algorithms graph-algorithm made-easy-test-series madeeasy-testseries-2018 + – Kalpataru Bose asked Jan 16, 2018 edited Mar 5, 2019 by ajaysoni1924 Kalpataru Bose 419 views answer comment Share Follow See all 4 Comments See all 4 4 Comments reply Ashwin Kulkarni commented Jan 16, 2018 i edited by Ashwin Kulkarni Jan 16, 2018 reply Follow Share In graph G1, min distance from A to B is 2 optimally. But dijakstra will compute it as 4. Hence it won't calculate correct shortest path. Here Question is not about dijakstra works or not. Hence only G2 is correct. 0 votes 0 votes SHUBHAM SHASTRI commented Jan 16, 2018 reply Follow Share a to b distance is 2 ...that is 8-4-2=2....it compute correctly 0 votes 0 votes Ashwin Kulkarni commented Jan 16, 2018 reply Follow Share @shubham At initial stage itself dijakstra will fix the distance a-b as 4 because min of {4,7,8}. Hence no chance to again change that to 2. 0 votes 0 votes SHUBHAM SHASTRI commented Jan 16, 2018 reply Follow Share yes you are correct... 0 votes 0 votes Please log in or register to add a comment.