    printf("From source %d",src);
    for(i=1;i<=n;i++)
    printf("The shortest distance to %d is %d",i,d[i]);
   //INITIALIZE SPANNING TREE EDGES
   int l=0;
   for (int it = 1; it <= n; ++it) {
   if(parent[it]==it) continue;    