Bus Routes
Return the least number of buses you must take to travel from source to target. Return -1 if it is not possible.
Return the least number of buses you must take to travel from source to target. Return -1 if it is not possible.
You are also given three integers src, dst, and k, return the cheapest price from src to dst with at most k stops. If there is no such route, return -1.
Return a deep copy (clone) of the graph.
For example, the pair [0, 1], indicates that to take course 0 you have to first take course 1. Return true if you can finish all courses. Otherwise, return false.
Return the ordering of courses you should take to finish all courses. If there are many valid answers, return any of them. If it is impossible to finish all courses, return an empty array.
Among all possible rooted trees, those with minimum height (i.e. min(h)) are called minimum height trees (MHTs).
Given an m x n 2D binary grid grid which represents a map of '1's (land) and '0's (water), return the number of islands.
There is an m x n rectangular island that borders both the Pacific Ocean and Atlantic Ocean. The Pacific Ocean touches the island's left and top edges, and the Atlantic Ocean touches the island's right and bottom edges.
Sort Items by Groups Respecting Dependencies...