You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Instantly share code, notes, and snippets.
🎯
Focusing
Rambabu Patidar
rambabu-patidar
🎯
Focusing
Learning Mode on .... || Finishing the projects are more imp than making them perfect....
Very very simple example of how you can use websocket for bi-directional communication between client and server.
WebSocket
This code comes from this youtube channel The Complete Guide to WebSockets one of the best channel to learn Networking and Deep dive
concepts of System Design etc.
Actually this has two version with slightly different ways but same functionality.
Dijkstra's Algorithm
We use Dijkstra algorithm to find the minimum distance from single srouce(src) to all other vertex in the given graph.
It works only on Undirected Weighted Graph which are not having negative edge weights.
It uses a greedy approach that repeatedly minimize the distances to other vertices.
We use priority queue to implement Dijkstra's algorithm.
__dirname : This gives us the path from the OS to the folder in which you used it. (important is folder here because we used this command in some file that reside inside that folder)
FOR EXAMPLE: C:\Users\Lenovo\Desktop\Fun\routes\shop.js this is the path in which we used __dirname then we will going to get path upto
C:\Users\Lenovo\Desktop\Fun\routes\
__filename: This command when used gives the full path from OS to the file in which we used it.
So for above example we will get C:\Users\Lenovo\Desktop\Fun\routes\shop.js
Now we know that node js ships with it a core module that is path module.
ST(Spanning Tree) is a tree like subgraph of a connected, undirected graph that include all the vertices of the graph.
In simple words, It is a tree like structure (hence no cycle) where the edges are the subset of graph and vertices are the exact set of original graph.
MST is excatly same like ST but with one more constraint of having minimum weight sum of edges.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
TestingLibraryElementError while build with Node.js workflow
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters