wait so what is the “most correct”? I initially thought it’s n*m but would it be more corrected for it to be V+E? And I’m kind of confused about the problem — like is it asking if an end is reachable — ie if a path exists to the end state?
2025-09-13 02:34:22
2
E-SAW!! :
thank God I didn't interview at big tech. having to do a DSA question for a fullstack developer position with a completely unrelated tech stack to what's advertised is nuts.
2025-09-14 08:56:00
0
blueberryjam87 :
me too
2025-09-13 19:19:16
0
anaf :
Im nosey what internship was it
2025-09-13 05:45:18
1
788 :
Correct me if I’m wrong but how would O(V+E) be any different than O(N^2)/O(NM)? Since we’re talking abt big O complexity, there won’t be a big O complexity that represents a more optimized version than another for the same algorithm since it’s an upper bound. But if V = number of squares in the grid (n^2/nm) or number of vertices, and E = 4(V), then it still reduces to O(n^2) or O(nm). This is a nit but just wanted to point it out because the only difference between using V,E, or N/M is depending on the language used in the type of problem being asked. Since this is a “grid” problem where they might define the grid as being a “n x m” grid it makes more sense in an interview to state big O in terms of n or m, and not v/e like what would might be used in a different graph problem with nodes/edges or a tree problem. Don’t think most interviewers would dock u for that tho, good breakdown and video!
2025-09-13 16:46:23
1
To see more videos from user @leo.deng49, please go to the Tikwm
homepage.