Paul,

Thanks for the response. I would like to rephrase my question. I have a number 
and would like to fudge it such that

It is unique and has a one to one mapping with the old number and it should be 
random and not predictable. Any possible solutions here.

Of course the fudged number could / can lie in a different number range 
slightly. Say a four digit number garbled could give me a unique random

6 six digit random number.


Thanks,
Kiran




________________________________
From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of Paul Herring
Sent: Thursday, May 29, 2008 5:43 PM
To: [email protected]
Subject: Re: [c-prog] Function for Unique Random Number Generator given a 
sequential number .....


On Thu, May 29, 2008 at 11:46 AM, Kiran Divakaran
<[EMAIL PROTECTED]<mailto:kiran_divakaran%40infosys.com>> wrote:
> Hi All,
>
> Have a need for a program to give out a unique random number given, provided 
> it takes a sequence number as an input.
>
> The requirement is that the value given to this function will be a sequential 
> number in the range 1-99999999.
>
> The function which takes this number is expected to return me a unique number 
> in the same range but random at the same time.
>
> Please let me know if anyone has used such algorithms in the past.

http://c-faq.com/lib/randrange.html

--
PJH

'Two Dead in Baghdad' not 'product-friendly' - Kent Ertugrul, chief
executive of Phorm.

http://shabbleland.myminicity.com/


**************** CAUTION - Disclaimer *****************
This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely 
for the use of the addressee(s). If you are not the intended recipient, please 
notify the sender by e-mail and delete the original message. Further, you are 
not 
to copy, disclose, or distribute this e-mail or its contents to any other 
person and 
any such actions are unlawful. This e-mail may contain viruses. Infosys has 
taken 
every reasonable precaution to minimize this risk, but is not liable for any 
damage 
you may sustain as a result of any virus in this e-mail. You should carry out 
your 
own virus checks before opening the e-mail or attachment. Infosys reserves the 
right to monitor and review the content of all messages sent to or from this 
e-mail 
address. Messages sent to or from this e-mail address may be stored on the 
Infosys e-mail system.
***INFOSYS******** End of Disclaimer ********INFOSYS***


[Non-text portions of this message have been removed]

Reply via email to