You can do it naively in O(N^2), but in order to do it in linear time, you need some algorithm to "topologically" order them... You are only given information for Person 1, so everything in the end has to be calculated relatively to the position of Person 1.
Greatt, thanks a ton ❤
Lowkey underrated. Keep doing what you’re doing.
In problem D is there any other way to solve the problem using maths or something else?
You can do it naively in O(N^2), but in order to do it in linear time, you need some algorithm to "topologically" order them... You are only given information for Person 1, so everything in the end has to be calculated relatively to the position of Person 1.
is it only me or this vid max resolution i can go is only 360p
I'm not sure, probably UA-cam was still processing it. Even though, it clearly said that it finished with processing. Should be fine now. 🙂