What is the error?

@garganshul151 input t!
also for different test cases don’t forget to clear map containing edges!

how to clear map for diff testcases?

also how to remove distance 0 of node 1 from output?

just do m.clear() to clear the map.

you can use a simple if statement for this thing!!!

giving compile error in submiting??

@garganshul151 share the code

@garganshul151 it’s working fine!

testcase is getting failed while submitting saying compile message–wrong answer

@garganshul151 you have to print -1 when dist==INT_MAX

https://ide.codingblocks.com/s/304142…still giving the error after updation

reply please its urgent

@garganshul151 the code I provided cleared the test case!
if you are facing problem, then you may download the test case and see.

do u submit in cb course? the same code of mine?

I submiited this code, which is yours