-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Added-Leetcode-Arrays-Adhoc-Problem #124
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @nishantagrawal01! Thanks for submitting this contribution, however I have a few questions/comments:
- Can you explain, with an example, what the
Arrays-Adhoc
pattern consists of? I haven't encountered something like this so far in ~300 questions and would love to learn more! - According to Leetcode Premium, this question isn't asked by Amazon - did you encounter this recently?
src/data/index.js
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please change this to 170
- the id
field isn't the id of the leetcode question in this case
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @seanprashad , thanks for the info. I have updated the pull req. Kindly please merge it.
Hey @nishantagrawal01! Thanks for submitting this contribution, however I have a few questions/comments:
- Can you explain, with an example, what the
Arrays-Adhoc
pattern consists of? I haven't encountered something like this so far in ~300 questions and would love to learn more!- According to Leetcode Premium, this question isn't asked by Amazon - did you encounter this recently?
Yes Sure. Actually ad-hoc problems are such kind of problems that doesn't basically require particular use of any fancy data structure/algorithm. These problems are also called constructive algorithms and are created in order to build logic even if a candidate is not much into intermediate/advanced level of Data structures/algorithms.
Yes, this was recently asked by amazon in an interview round.
Let me give you an example. Below is the problem statement
Given an array arr[], find the maximum j – i such that arr[j] > arr[i].
This is a ad-hoc problem, I couldn't find it on leetcode so I didn't add this one in the list.
No description provided.