Given an array of int[] like 1,2,3 Find the next largest integer than can be made with these digits (e.g.: 2,1,3)
Engineer Developer Interview Questions
467,034 engineer developer interview questions shared by candidates
List of n number with k numbers missing. How do you identify the missing numbers? What is the run time?
Given an array a contains all digits 0-9 a = [1, 4, 2, 1] # which represents 1421 Add one to the number and return the array return a = [1, 4, 2, 2] # which represents 1422
Except experience related questions I was asked coding question and I was supposed to write the solution to the problem in any programming language in a simple web-based code editor. The question was: given and array of positive integers and another integer find whether there is a consecutive range in the array, so that the sum of integers in the range is equal to the given number. They put an emphasis on delivering working, efficient solution. In my opinion this kind of interview requires a thorough preparation.
Given a string, remove all chars from the string that are present in say another string called filter.
Given sorted arrays of length n and 2n with n elements each, merge first array into second array.
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.
Print a binary tree level by level
Given an integer, if the number is prime, return 1. Otherwise return its smallest divisor greater than 1. e.g. if n = 24, its divisors are [1, 2, 3, 4, 6, 8, 12, 24]. The smallest divisor greater than 1 is 2.
Q: You are given two arrays of size m and n. Find the common elements between those arrays. Say, arr1 = {2, 5, 3} and arr2 = {5, 1, 2}. The common elements between those arrays are as follow: ans = {2, 5}
Viewing 601 - 610 interview questions