- My Forums
- Tiger Rant
- LSU Recruiting
- SEC Rant
- Saints Talk
- Pelicans Talk
- More Sports Board
- Fantasy Sports
- Golf Board
- Soccer Board
- O-T Lounge
- Tech Board
- Home/Garden Board
- Outdoor Board
- Health/Fitness Board
- Movie/TV Board
- Book Board
- Music Board
- Political Talk
- Money Talk
- Fark Board
- Gaming Board
- Travel Board
- Food/Drink Board
- Ticket Exchange
- TD Help Board
Customize My Forums- View All Forums
- Show Left Links
- Topic Sort Options
- Trending Topics
- Recent Topics
- Active Topics
Started By
Message
re: Nigerian software engineer detained by U.S. Customs at airport and given test
Posted on 3/1/17 at 2:34 pm to Street Hawk
Posted on 3/1/17 at 2:34 pm to Street Hawk
So did he answer it or no?
It doesn't sound like they asked for the most efficient answer, so all he had to do was iterate the tree, find the median, then sort left and right based on the median. Voila, balanced tree. While not the most efficient approach, it will give the correct answer.
A real engineer should be able to think of trivial, inefficient answers like this.
It doesn't sound like they asked for the most efficient answer, so all he had to do was iterate the tree, find the median, then sort left and right based on the median. Voila, balanced tree. While not the most efficient approach, it will give the correct answer.
A real engineer should be able to think of trivial, inefficient answers like this.
Popular
Back to top
Follow TigerDroppings for LSU Football News