Engineer ii Interview Questions | Glassdoor.co.in

Engineer ii Interview Questions

755

engineer ii interview questions shared by candidates

Top Interview Questions

Sort: RelevancePopular Date

Given an large list of unsorted numbers, find the smallest number. You can access the list only 3 numbers at a time, and keep moving forward 1 number at a time.

6 Answers

Otherwise called the sliding window problem

Use the selection sort and after the pass stop the iterating. Time complexity will be O(N) & only one swap.

Use the selection sort and after the first pass stop the iterating. Time complexity will be O(N) & only one swap.

You are given an array of numbers. You need to print the length of the maximum continuous sequence that you encounter. For example if input is [3,8,10,1,9,6,5,7,2 ], the continuous sequences are{1,2,3} and {5,6,7,8,9,10} the latter is the longest one so the answer becomes 6. O(n) solution was asked for, assuming you have a hash map which supports O(1) insertion and fetching operations

6 Answers

1. Test Case Enumeration: Write test cases for taxi booking application for Ola or Uber. You are expected to write testcases covering different types of functional and non-functional testing areas 2. Problem Solving: Find the first occurance of a given number from the series which has the difference between the adjacent elements as 1. For Example {1, 0, -1,-2,-1,0,1,2,3} Note: Do not use Linear Search 3. Test Data Generation Write the test data for the function: int getSmallestIntegerPosition(int[] A) This method accepts as input integer array that is already sorted and rotated "n" number of items where n is less than the size of the array For Example: The test data can be {4,5,6,1} This was derived from {1, 4, 5,6} afer sorting and rotating the array for 3 times And output of the function returns the index of integer that has the smallest value Eg: {4,5,6,1}: the smallest value is 1 and its index is 3 Note: This method searches for the element and derives the position with an order of O(log(n)) 4. Debugging While using skype or google hangout application, you are not able to do a video chat, describe how you debug the problem considering different aspects of functional and non-functional testing 5. Scripting Find the nth consecutive occurence of a character in a given string. For example for the given input string of "Amazon is a great company as it haas AtoooZzz" and the output should be "o" 6. Consider a string "Hello Good Morning" it should print the sentence in reverse order output should be "Morning Good Hello" 7. Check two strings are anagram 8. Merge two dimesional Array Consider array1={{10, 15}, {30, 50}} array2={{20,40}, {5, 10}} Merged array should be sandwitched (array 1 should be sandwitched with array 2) also while merging array if value range is less than the previously added value then that value should not be added to the merged array Output should be {10, 20, 30, 40, 50} --> 15, 5 and 10 should not be added 9. Print middle character of a string. If middle value has even then print 2 characters Eg: Amazon -->print az 10. Search an element in array without using linear search technique 11. Write test cases for Amazon Prime functionality 12. Testcases enumeration and data preperation for Whatsapp messenger

6 Answers

Two sorted arrays. you can start from any one them, and then at common element you may or may not jump to other array. Continue in this manner till you reach the end of an array. Find the path that results the maximum sum.

3 Answers

1. You built an application like google drive. State the test cases 2. You are trying to upload a picture on facebook and it is not loading. List out the possible errors 3. Reverse alternate words in a sentence

4 Answers

Trees, DP, Arrays

3 Answers

Q: How do you flat an Array?

3 Answers

Remove all characters of a string from another string. The algorithm should be less than O(m*n) where m & n are lengths of strings and the space used should be less than O(m+n).

3 Answers

rainwater collection problem

2 Answers

I was asked two questions. One was given an array of integers find triplets such that a^2 + b^2 = c^2.

2 Answers
110 of 755 Interview Questions