Saturday, November 3, 2012
Given two set , 1st one is of 1 to n numbers where n is very very large say this set T and other set is very small contains only number {3,5,7} , Now generate all number from set T (bigger) except element in smaller set , with "equal probability" , you have given rand function , also minimize the call to rand function so solve it in most optimal way
Labels:Data
Google Interview
Subscribe to:
Post Comments
(
Atom
)
No comments :
Post a Comment