Software Development Engineer Interview Questions | Glassdoor

Software Development Engineer Interview Questions

4,103

Software development engineer interview questions shared by candidates

Top Interview Questions

Sort: RelevancePopular Date

Write a method to decide if the given binary tree is a binary search tree or not.

4 Answers

for binary search tree, inorder traversal should result in sorted array in the increasing order.

Further, know that the difference between the two is that a binary search tree cannot contain duplicate entries. recur down the tree - check if element is already in hashtable - - if it is, return false - - if it isnt, insert element into the hashtable - - - recur to children

I'm sorry but Anon's answer is not correct, at least according to "Introduction to Algorithms, 3d Edition" by Cormen. The binary search tree property says that there CAN be duplicates: "Let x be a node in a binary search tree. If y is a node in the left subtree of x, then y.key = x.key." In other words, the value of a child node may be equal to the value of a parent node, which would yield the result that "Interview Candidate" posted on Mar 14 2012. Performing an inorder tree walk would yield sorted nodes.

In a given sorted array of integers remove all the duplicates.

8 Answers

how can a particular application be tested apart from testing its functionality

3 Answers

Write code in your favorite programming language that will accept two strings and return true if they are anagrams.

2 Answers

Lots of questions about arrays, lists and hashmaps

1 Answer

Given a string (understood to be a sentence), reverse the order of the words. "Hello world" becomes "world Hello"

2 Answers

Write an algorithm to determine if 2 linked lists intersect

15 Answers

Find the deepest common ancestor of two nodes in a tree structure.

13 Answers

The Game of Nim worded diffently.

11 Answers

Most of them were expected. Almost all are problem solving questions. 1. Given a BST with following property find the LCA of two given nodes. Property : All children has information about their parents but the parents do not have information about their children nodes. Constraint - no additional space can be used

15 Answers
110 of 4,103 Interview Questions