is a comprehensive book on getting a job at a top tech company, while focuses on dev interviews and does this for PMs.
CareerCup's interview videos give you a real-life look at technical interviews. In these unscripted videos, watch how other candidates handle tough questions and how the interviewer thinks about their performance.
Most engineers make critical mistakes on their resumes -- we can fix your resume with our custom resume review service. And, we use fellow engineers as our resume reviewers, so you can be sure that we "get" what you're saying.
Our Mock Interviews will be conducted "in character" just like a real interview, and can focus on whatever topics you want. All our interviewers have worked for Microsoft, Google or Amazon, you know you'll get a true-to-life experience.
We can consider some simple cases.
- gautamjha.jnu December 09, 20141. If the smallest number in array is greater than 1 then we can simply report 1 as answer.
2. If this is not the case , then sort the array.
After sorting we can apply more simple cases.
like if our sorted array is
[1 3 4 5] -- so we know that 2 cannot be formed using sum
[1 2 4 9] -- so we know that 8 cannot be formed using sum
so if sum of array A[1- (n-1) ] is smaller than A[n] , then we can report SUM( A[1 - (n-1) ] as answer.
If we complete the complete traversal of array and we could find and answer, we can report SUM(A[1 - n] ) as answer.