Windows Development Software Engineer Interview Questions | Glassdoor

Windows Development Software Engineer Interview Questions


Windows development software engineer interview questions shared by candidates

Top Interview Questions

Sort: Relevance Popular Date

Assume that you are given the head and tail pointers of a doubly linked list where each node can also have a single child pointer to another similar doubly linked list. There are no cycles in this structure outside of the traditional double links. Write a procedure in C++ that flattens this structure into a single list.

7 Answers

I found out later that this problem is one of several classic programming questions taken from an interview book. Such a list has an obvious recursive structure, but it is large and so recursion is not practical. Consequently, an iterative approach is necessary. The invariant for such an approach maintains the flat list to the "left" and the possibly fat list to the "right."

Do you know the name of the book?

I don't know the particular book it was taken from. However, a colleague recommends the book: _Programming Interviews Exposed_ by John Mongan The second edition is available, but a third edition (with two additional authors) is on its way and available for pre-order on Amazon. There are several other similar books. For example, _Cracking the Coding Interview: 150 Programming Questions and Solutions_ by Gayle Laakmann McDowell _Programming Pearls_ by Jon Bently _Puzzles for Programmers and Pros_ by Dennis Shasha _How Would You Move Mount Fuji?: Microsoft's Cult of the Puzzle -- How the World's Smartest Companies Select the Most Creative Thinkers_ by William Poundstone and many others you can probably find by looking at Amazon's recommendations when viewing the descriptions of those books.

Write a procedure in C that reverses the letters of a null-terminated string. Then write another procedure in C that reverses the words of a null-terminated sentence.

1 Answer