Engineer Intern Interview Questions

15,322 engineer intern interview questions shared by candidates

phone numbers: provided a phone number (654-876-0987), return all possible strings that the phone number could represent if 2 -> {A, B, C}, 3 -> {D, E, F}, and so on common substring: find the biggest common substring in 2 strings, "abcdef" "gbcdh" would return "bcd"
avatar

Software Engineer Intern

Interviewed at Meta

3.6
Oct 11, 2012

phone numbers: provided a phone number (654-876-0987), return all possible strings that the phone number could represent if 2 -> {A, B, C}, 3 -> {D, E, F}, and so on common substring: find the biggest common substring in 2 strings, "abcdef" "gbcdh" would return "bcd"

Write a function to determine if a bin tree is a valid BST. I wrote a fully working solution in 3-5 minutes. It was also the most optimal but maybe because she needed to kill time, she asked me to rewrite it in what she thought was optimal (her reasoning didn't make much sense). Then she asked me for time and space requirements of the solutions. I said O(n) for both which is correct but she insisted that the space requirement was O(logn) which is wrong.
avatar

Software Engineer Intern

Interviewed at Meta

3.6
Jan 15, 2013

Write a function to determine if a bin tree is a valid BST. I wrote a fully working solution in 3-5 minutes. It was also the most optimal but maybe because she needed to kill time, she asked me to rewrite it in what she thought was optimal (her reasoning didn't make much sense). Then she asked me for time and space requirements of the solutions. I said O(n) for both which is correct but she insisted that the space requirement was O(logn) which is wrong.

Write a function in Java that will take a sorted array of ints, possibly with duplicates, and compact the array removing all the duplicate numbers. That is, if the contains the numbers - 1, 3, 7, 7, 8, 9, 9, 9, 10, then when the function returns, the contents should be - 1, 3, 7, 8, 9, 10. Be sure your answer is as efficient as possible. Describe the efficiency of your algorithm using big O notation.
avatar

Software Engineer Intern

Interviewed at Motorola Mobility

4.2
Mar 19, 2009

Write a function in Java that will take a sorted array of ints, possibly with duplicates, and compact the array removing all the duplicate numbers. That is, if the contains the numbers - 1, 3, 7, 7, 8, 9, 9, 9, 10, then when the function returns, the contents should be - 1, 3, 7, 8, 9, 10. Be sure your answer is as efficient as possible. Describe the efficiency of your algorithm using big O notation.

Given a binary tree, which is not necessarily balanced, print the nodes in the tree in a level-wise manner. Also, nodes on the same level should be printed on a single line. A modification of the question was added later in which I cannot really add a "level" variable in the structure of the node in the tree.
avatar

Software Engineer Intern

Interviewed at Meta

3.6
Aug 13, 2013

Given a binary tree, which is not necessarily balanced, print the nodes in the tree in a level-wise manner. Also, nodes on the same level should be printed on a single line. A modification of the question was added later in which I cannot really add a "level" variable in the structure of the node in the tree.

Viewing 51 - 60 interview questions

Glassdoor has 15,322 interview questions and reports from Engineer intern interviews. Prepare for your interview. Get hired. Love your job.