Jobs in India
Search Jobs
Search Jobs
Advertisements

Test Paper Chennai November 2011 by Yahoo

Details of Test Paper Chennai November 2011 by Yahoo conducted by Yahoo for job interview.
Advertisements
The process followed by Yahoo India was

1) Short listing on basis of CGPA
2) Written Test
3) Interview

Shortlisted on the basis of CGPA

Written Test:

Questions: 25 questions time 1 hour.
All Questions are multiple types

1. Teacher asked the students to find the cube root of a natural number but she did not mention the base. Students assumed the base found the cube root. Each student got an integer. Find the sum of digits of that number.
A. 0 B. 1 C. 6 D. 7 E. 8

2. What is the difference of last two digits of N where N=7^2010
a. 1 b.3 c.5 d.7 e.9

3. Find the first non Zero digit in 67!(Factorial)
a. 3 b.4 c.5 d.6 e.7

4. Suppose here are n processes in the system and each one needs k instances of a resources to complete. What would be the minimum number of resources that you should keep in the system to ensure no deadlock in the system.
a. n*k b. n*k-n+1 c. n*k+1 d. n*k*k e. None of the above

5. If we have a ring counter of 4 bits, with an initial state of 1000, what is the modulus of the counter?
a. 16 b.8 c.32 d.4 e. Node of the above

6. Which of the following masks can be used to zero out alternate bits of a 16 bit number?
a. 0101 b. AAAA c. FFFF d. EEEE e. BBBB
7. We define a function below. What is the value returned by this function: express your answer as a function of n?
unsigned int func(unsigned int n)
{
unsigned int r=0;
unsigned int i,j,k;
for(i=1;i>1);
}
A. Return the greatest integer smaller then x
B. Returns x/2
C. Returns the smallest integer greater than x with the some number of bits set
D. Returns the smallest integer greater than x with less number of bits set
E. None of the above

Question 14.
Int i
Void intcrement(int i)
{
I++
}
Int main()
{
For(i=0;ii do
j=j-1
end while end for
Assume the above procedure are only an integer n>0; What is the time complexity in n for the procedure above:

A. O(nlogn)
B. O(n)
C. O(n^2)
D. O(N^3)
E. O(1)
Question 22.
The worst case time complexity of finding 5th smallest number in sa list of 50000 randomly chosen numbers.

A. O(1)
B. O(n)
C. O(logn)
D. O(n^2)
E. O(nlogn)
Question 23.
Consider the problem of sorting (in ascending order ) of an array of numbers, each number being the range(50,000 5000,000). What sorting algorithm is the best choice for the above problem. What is the best case time complexity of sorting achievable for this problem?

A. Merge sort
B. Insertion Sort
C. Quick Sort
D. Counting sort
E. Bubble SOrt
Question 24.
Two matrices M1 And M2 are to be stored in an Array A and b respectively. Each Array can be stored either in row major r column major order in contiguous memory locations. The time complexity to compute M1*M2 (Matrix Multipication) will be

A. Best if A is in row-major and B is in Column Major Order.
B. Best if both are in row major
C. Best if both are in column major
D. Independent of the storage scheme.
E. None of the above
Question 25.
An large array[]1n] with N slots is filled only up to positions n for the n very less than N. To start with we do not know n. To locate an empty slot, we check A[j] for j=2^[2^i] in step i. What is the fewest number of steps in which we are guaranteed to find an empty slot?

A. O(n)
B. O(log n)
C. O(logN)
D. O(loglog n)
E. O(loglogN)