Forward Deployed Engineer Interview Questions | Glassdoor

# Forward Deployed Engineer Interview Questions

81

Forward deployed engineer interview questions shared by candidates

## Top Interview Questions

Sort: RelevancePopular Date

### Forward Deployed Engineer at Palantir Technologies was asked...

Dec 3, 2013
 How would you program a computer to shuffle a deck of cards? (Generate a permutation of the numbers from 1 to 100, uniformly at random)4 Answershttp://en.wikipedia.org/wiki/Random_permutation (See Knuth shuffle)Make array of numbers from 1 to 52. Go through each of cards each time removing one number randomly chosen from array and assigning it to the card. Sort the cards by numbers assigned to cardsI think you can use some group theory to solve this as well. Pick random number a in [0,51]. Pick another number b in [1,51] such that the gcd(52,b) = 1. The nth card in the permutation is the card at the index given by a+bn % 52, where % means modulus. i.e. nth index = a+bn (mod 52) In addition, this method works for any permutation of any length (assuming random distribution of b values).Show More ResponsesEasy way : assign a random number to each card (O(n), possibly by using an intermediate object of some kind like a Tuple), sort by this random number (O(n.log(n)) and you're done (final complexity O(n.log(n))). I don't see a more efficient way to do it without breaking the random distribution, but a deck of cards rarely have more than k*52 cards (with k small), so it wouldn't really matter anyway in the real world.

### Forward Deployed Software Engineer at Palantir Technologies was asked...

Sep 29, 2015
 Given an nxn matrix of 1's and 0's, figure out if all of the 1's are connected.2 AnswersCount all 1's in the matrix and store the number in a variable. Then use a dfs or bfs starting from a node with a 1, considering any adjacent 1 entries as neighbors. Count the number of entries reached through the search. If it's equal to the total number of 1's in the array, return true. Otherwise, return false.Keep a hash set of nodes already visited. Count the number of 1s in the matrix and store that in some int variable count. Iterate through matrix until a node with 1 is found. Use dfs or bfs starting from this node to visit all nodes with 1, checking each time if that node is contained in your hash set to avoid revisiting nodes and then adding to that hash set if the node has not been visited yet. After traversal is done, compare count to size of hashset. If equal, then return true else return false.

### Forward Deployed Engineer at Palantir Technologies was asked...

Mar 4, 2013
 The following question was the programming question during the second phone interview. The coding portion was conducted using Stypi (similar to Google Docs). I was allowed to use my language of choice (Python) rather than being forced to use Java. I was asked to write a routine to verify that all the words in the solution of a crossword puzzle were valid words. The crossword puzzle was represented as a two-dimensional array of single-character strings (and empty strings for the empty blocks). While this question is pretty straightforward, but there is a "better" solution than others which seemed to pique the interest of the interviewer—see the answer section for details. It is also worth pointing out that I later found that certain technical details of my solution were incorrect, but either the interviewer didn't notice or didn't care. I think the question was intended more to see how I work.1 AnswerIn order to verify a crossword, you need to check words across and down. While the obvious solution is to code both directions separately, the more elegant solution is to transpose the crossword as you would a matrix. Then you need to write code for only one direction (the "across" code is easiest) and verify that all the words in that direction for the original crossword and the transposed crossword are the same. If your language of choice does not have built-in operator or function for matrix transposition like Python does, the interviewer would probably let you assume the existence of such a function in the standard language library (since it is a relatively common operation).

### Forward Deployed Software Engineer at Palantir Technologies was asked...

Apr 8, 2015
 Given an array and an index within that array, rotate the array from that index of rotation Example : Input => [1,2,3,4,5] , 3 Output => [4,5,1,2,3]1 AnswerStandard solution : Rotate from 0 to index of rotation -1 [ 3,2,1,4,5] Rotate from index of rotation to end [3,2,1,5,4] Rotate the whole array [4,5,1,2,3] Couldn't get this right on the phone

### Forward Deployment Engineer at Palantir Technologies was asked...

May 2, 2012
 Everyone in the company does everything, and everyone in the group has a get it done attitude. How do you feel about that?1 AnswerWhat? That's me! I do everything, and I have a get it done attitude (if the compensation is correct. )

### Forward Deployment Engineer at Palantir Technologies was asked...

May 2, 2012
 What controls naming services on a Linux system1 Answernsswitch.conf

### Forward Deployed Engineer at Palantir Technologies was asked...

May 6, 2011
 Describe an algorithm for finding a duplicate character in a string.2 AnswersConsider time and space efficiency, and be prepared to describe using Big O notation.brute force: check every character against the rest. time efficient: use some sort of map to keep track of seen characters. alt: if the character space is small, then use some type of bit vector.

### Forward Deployed Engineer at Palantir Technologies was asked...

Feb 10, 2013
 (Coding question:) Verify that a crossword puzzle is correct. This means checking to see that any white square can reach any other white square by moving orthogonally along white squares (not checking to see if answers are correct.1 AnswerThere isn't necessarily one correct answer.

### Forward Deployed Engineer at Palantir Technologies was asked...

Jul 28, 2017
 My problem decomp was to build Asteroids.1 AnswerI built asteroids. Try to add features that demonstrate thoughtfulness for yours.

### Forward Deployed Engineer Intern at Palantir Technologies was asked...

Mar 29, 2013
 Given a corpus of valid words, design a function that takes a word as input and outputs all valid anagrams of that word.1 AnswerUse a hashmap with a special hash function where x and y collide iff x is an anagram of y. The first option is to sort each word and use that as the hash key. The second option, assuming an n-character encoding scheme, is to generate the first n primes and map each character to a unique prime. Then hashing consists of converting each character in a word to the associated prime and multiplying, which is faster and satisfies the collision criterion due to the Fundamental Theorem of Arithmetic.
110 of 81 Interview Questions