Given a binary tree, write a function to find the length of the longest path in the tree.
Software Engineer Interview Questions
466,387 software engineer interview questions shared by candidates
Write a function that computes log2() using sqrt().
Create a linked list with 3 char (A,B,C) in it and print the list in reverse.
Write a C function to return the number of set bits in an integer.
Given the following struct definition in C, what would sizeof(myStruct) return? typedef struct { short a; long b; char c; } myStruct;
Explain the data structure you would use to implement pop() and push(Object, int) for a Priority Queue.
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.
If you have a program that runs slow, how will you improve it to run faster?
What is the angle between the two arms of the clock at 2:40?
Sort a array, [W B W B B W W B ] === [W W W W B B B B ]
Viewing 241 - 250 interview questions