#graph
Read more stories on Hashnode
Articles with this tag
Link: https://www.geeksforgeeks.org/problems/print-adjacency-list-1587115620/1 · class Solution { public List<List<Integer>> printGraph(int V, int...
[Problem Link] https://leetcode.com/problems/rotting-oranges/ · class State{ int n; int time; public State(int n, int time){ this.n...
[Problem Link] https://leetcode.com/problems/number-of-islands/ · class Solution { private int[][] dir = {{1,0}, {-1,0}, {0,1}, {0,-1}}; public...
[Problem Link] https://leetcode.com/problems/01-matrix/ · class Solution { private int[][] dir = {{0,1}, {0,-1}, {1,0}, {-1,0}}; public int[][]...
[Problem Link] https://leetcode.com/problems/flood-fill/ · class Solution { public int[][] dir = {{0,1} , {0,-1} , {1,0} , {-1,0}}; public...