Developer Interview Questions

270,881 developer interview questions shared by candidates

You are given an array of integers, a1, that have sequential integers 1 through n. ( { 1,2,3,4,5 } or { 1,2,3 } or any other array) You are also given an array of integers, a2, that also have numbers 1 through n, but are not in sequential order and are missing one of the numbers between 1 and n. Find the missing number in a2. Did you check for special cases? Can you do this in O(n) runtime?
avatar

Software Developer Intern

Interviewed at Redfin

3.5
Feb 19, 2016

You are given an array of integers, a1, that have sequential integers 1 through n. ( { 1,2,3,4,5 } or { 1,2,3 } or any other array) You are also given an array of integers, a2, that also have numbers 1 through n, but are not in sequential order and are missing one of the numbers between 1 and n. Find the missing number in a2. Did you check for special cases? Can you do this in O(n) runtime?

Puzzle1 - Given 8 coins, and the fact that one of the coins is heavier than the other, how many times(min) do you need to use a beam balance to figure out which is the anomalous coin? After I answered this, he made it little tougher. Given 9 coins and one anomalous coin(maybe heavier or lighter), figure out which coin it is and whether heavier or lighter. What is the min no of comparisons? This is where i took a while to answer.
avatar

Financial Software Developer

Interviewed at Bloomberg

4
Nov 16, 2010

Puzzle1 - Given 8 coins, and the fact that one of the coins is heavier than the other, how many times(min) do you need to use a beam balance to figure out which is the anomalous coin? After I answered this, he made it little tougher. Given 9 coins and one anomalous coin(maybe heavier or lighter), figure out which coin it is and whether heavier or lighter. What is the min no of comparisons? This is where i took a while to answer.

Your photo-sharing app displays a system notification when the user receives a photo. Your app should display the photo when the user taps the notification. Which of the following do you need to attach to the Notification object that you pass to NotificationManager? A. An Activity reference B. A PendingIntent C. A BroadcastReceiver D. A Fragment transaction
avatar

Android Developer

Interviewed at Meta

3.6
May 1, 2015

Your photo-sharing app displays a system notification when the user receives a photo. Your app should display the photo when the user taps the notification. Which of the following do you need to attach to the Notification object that you pass to NotificationManager? A. An Activity reference B. A PendingIntent C. A BroadcastReceiver D. A Fragment transaction

Viewing 191 - 200 interview questions

Glassdoor has 270,881 interview questions and reports from Developer interviews. Prepare for your interview. Get hired. Love your job.