 |
 |
 |
|
|
| |
|
|
 |
| |
 |
|
 |
 |
 |
 |
 |
At
Microsoft India Development
Center our teams develop
strategic products for Microsoft
|
|
| |
|
|
 |
 |
|
 |
|
 |
|
 |
|
 |
|
 |
|
|
|
 |
|
|
 |
 |
| |
 |
| |
 |
|
| An
island is inhabited by five men and
a pet monkey. One afternoon the men
gathered a large pile of coconuts, which
they proposed to divide equally among
themselves the next morning. During
the night one of the men awoke and decided
to help himself to his share of nuts.
In dividing them into five equal parts
he found that there was one nut left
over. This one he gave to the monkey.
He then hid his one-fifty share, leaving
the rest in a single pile. Later another
man awoke with the same idea in mind.
He went to pile, divided into five equal
parts, and gave one coconut left over
to monkey, hid his one-fifth share,
restoring the rest to one pile. During
that night each of the other three men
followed the same procedure. Each time
one coconut was left over and it was
given to the monkey. The next morning
all five men went to the diminished
nut pile and divided it into five equal
parts, finding one nut remained over.
What is the least number of coconuts
the original pile could have contained?
What is the answer if 11 men were present
instead of five in the above problem? |
 |
 |
 |
|
In
Fibonacci series f(1) = 1, f(2) = 1
and f(n+1) = f(n) +
f(n-1). Given that calculate the following
Sum (f(1))/1 + (3 * f(2))/5 + (3**2
* f(3))/(5**2) + ............+ ((3**n)
* f(n+1))/(5**n) |
 |
 |
 |
|
| You
are given one carpet each of 8 * 8 size
and 6 * 1 size. You need to make a 7
* 10 carpet from these two carpets.
You can make 8 * 8 carpet into two pieces
(any shape) only. How do you divide
the 8 * 8 carpet and use the 3 pieces
to make 7 * 10 carpet. |
 |
 |
 |
|
| There
are 2N number of parking slots in a
campus. To park a scooter you need 1
parking slot and to park a car you need
2 (adjacent) parking slots. How many
different ways you can park cars and
scooters (combinations) (assuming you
have 2N scooters and N cars) |
 |
 |
 |
|
| Optimal
Number of Moves: How many minimum number
of moves are needed to cross N steps,
where you start with 1 step and each
in each next move you take 1 less than
or 1 more than the number of steps you
have taken in the previous move. |
 |
| 1. |
ex: to cross 3 we can take 1 followed
by 2 (2 moves) |
|
 |
| 2. |
ex: to cross 7 steps we take 1,
2, 1, 2, 1 (5 moves) |
|
 |
 |
 |
|
 |
|
|
 |
 |
 |
 |
 |
 |
 |
| Here
are some of the questions that the code4bill contestants
answered. How about trying your hand at them? |
| • |
Multiply
14332 represented in base -7 with 16430 represented
in base -8 and represent the output in base -9. |
| • |
An array
contains 9 occurrences of 0s, 8 occurrences of 1s and
7 occurrences of 2s in any order. The array is to be
sorted using only swap operations. What is the minimum
number of swaps needed in the worst case to sort the
array? |
| • |
You are given an infinite number of cookie boxes containing either 6, 9 or 400 cookies. You are allowed to use these boxes in any combination so desired. What is the maximum number of cookies that you cannot give out using the above boxes? |
|
|
 |
|
 |
|
 |
|
 |
 |
| |
|
|
 |
|
|
|
|
|