Yahoo Interview Report
- 0of 0 votes
AnswersYou are given have a datatype, say X in C. Determine the size of the datatype,
- gullu September 12, 2010
without declaring a variable or a pointer variable of that type, and, of course without using
the sizeof operator!| Report Duplicate | Flag | PURGE
Yahoo Software Engineer / Developer C - 0of 0 votes
AnswersWrite a C Program to reverse a stack in place using recursion. You can only
- gullu September 12, 2010
use the following ADT functions on stack: IsEmpty, IsFull, Push, Pop, Top
you can not use extra stack or any other data structure| Report Duplicate | Flag | PURGE
Yahoo Software Engineer / Developer Algorithm - 1of 1 vote
AnswersThere is a sequence of increasing numbers that have the same number of
- gullu September 12, 2010
binary 1s in them. Given n, the number of 1 bits set in each number, write an algorithm
or C program to find the n’th number in the series| Report Duplicate | Flag | PURGE
Yahoo Software Engineer / Developer Algorithm - 0of 0 votes
AnswersYou are given a list of Ball objects. Each Ball is either Red or Blue. Write a function that partitions these balls so that all of the balls of each color are contiguous. Return
- gullu September 12, 2010
the index of the first ball of the second color (your result can be Red balls, then Blue balls, or the other way around). In haskell, you’ll probably want to return a ([Ball],Int).| Report Duplicate | Flag | PURGE
Yahoo Software Engineer / Developer Algorithm - 0of 0 votes
AnswersGiven a stack S, write a C program to sort the stack (in ascending order).
- gullu September 12, 2010
You are not allowed to make any assumptions about how the stack is implemented; the only
functions allowed to be used are: Push, Pop, Top, IsEmpty, IsFull.| Report Duplicate | Flag | PURGE
Yahoo Software Engineer / Developer Algorithm - 0of 0 votes
AnswersWrite a program to find and print the 1500’th ugly number.
- gullu September 12, 2010| Report Duplicate | Flag | PURGE
Yahoo Software Engineer / Developer Algorithm - 0of 0 votes
AnswersGiven two sets, Write a function to provide the union of them.
- gullu September 12, 2010| Report Duplicate | Flag | PURGE
Yahoo Software Engineer / Developer Algorithm - 0of 0 votes
AnswersGiven an array of integers. The sum of the elements of the array is known to be less than the max integer. Compute the sum.
- gullu September 12, 2010
What if we know that integers are in 2's complement form?| Report Duplicate | Flag | PURGE
Yahoo Software Engineer / Developer Algorithm