Microsoft Interview Question for Developer Program Engineers
- 0of 0 votes
Write pseudo code for Optimal game stratagy:- sse July 05, 2012 in United States
You have X amount with you, and 2N cards (N - winning cards, and N-loosing cards).
you have to play all the cards.
all cards are well shuffled, and one card is drawn randomly for each time.
if you pic one card means, next time you have to take one card from rest of the cards, i.e at last of the game you will left with one card.
If you bet 100 rupees,
If you got winning card ===> then you will get 200 rupees,
If you got a loosing card ====> then you will loose all your betting amount.i.e 100 rupees in this case.
You need to play all the cards. (I solved it.)
He asked me to solve it, with card replacement, i.e every time one card is drawn from 2N CARDS.
| Report Duplicate | Flag | PURGE
Microsoft Developer Program Engineer Algorithm
Interview Type: In-Person
Open Chat in New Window