Interns Interview Questions

248,188 interns interview questions shared by candidates

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.

how would you design how a cellphone implements its contact list when you press a certain letter. For example, If you press M it will tell you all the names starting with M. then if you press MI it will tell you all names starting from MI and so forth....
avatar

Amazon Software Developer Intern

Interviewed at Amazon

3.5
Apr 1, 2011

how would you design how a cellphone implements its contact list when you press a certain letter. For example, If you press M it will tell you all the names starting with M. then if you press MI it will tell you all names starting from MI and so forth....

The interviewer gives you 100 blank cards, and you can write a single positive integer on each card. The interviewer looks at the cards when you're done (so he knows the probability distribution of the deck), then shuffles the deck. The interviewer guesses the top card of the deck, and if he's right, he makes in $ the number written on the card. What numbers should you write on the cards to minimize the expected return of the interviewer?
avatar

Trading Intern

Interviewed at Jane Street

4.4
Apr 23, 2014

The interviewer gives you 100 blank cards, and you can write a single positive integer on each card. The interviewer looks at the cards when you're done (so he knows the probability distribution of the deck), then shuffles the deck. The interviewer guesses the top card of the deck, and if he's right, he makes in $ the number written on the card. What numbers should you write on the cards to minimize the expected return of the interviewer?

Viewing 181 - 190 interview questions

Glassdoor has 248,188 interview questions and reports from Interns interviews. Prepare for your interview. Get hired. Love your job.