We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
- Sorting: Comparator
- Discussions
Sorting: Comparator
Sorting: Comparator
Sort by
recency
|
496 Discussions
|
Please Login in order to post a comment
The R solution that goes with the setup I posted a minute ago is,
The R option has no pre-populated code, so here's what it would look like if it were analogous to the setup for python:
I believe many people have misunderstood the assessment. This is not an exercise in using a language's standard library; it's an exercise in implementing a sorting algorithm from scratch. Most of the solutions I've seen simply call the .sort method provided by the chosen language. This approach does not demonstrate your ability to implement your own sorting algorithm. In a FAANG algorithm interview, relying on built-in sort methods likely won't be acceptable. You need to show that you can write and understand sorting algorithms on your own.
my solution in c#
my solution in Go: