SI
SI
discoversearch

We've detected that you're using an ad content blocking browser plug-in or feature. Ads provide a critical source of revenue to the continued operation of Silicon Investor.  We ask that you disable ad blocking while on Silicon Investor in the best interests of our community.  If you are not using an ad blocker but are still receiving this message, make sure your browser's tracking protection is set to the 'standard' level.
Technology Stocks : Advanced Micro Devices - Moderated (AMD)
AMD 213.43+6.2%Dec 19 9:30 AM EST

 Public ReplyPrvt ReplyMark as Last ReadFilePrevious 10Next 10PreviousNext  
To: kapkan4u who wrote (65037)12/6/2001 12:09:20 PM
From: Joe NYCRead Replies (1) of 275872
 
Kap,

I may be missing something. How is the index determined? The switch value is an integer, which can be any number up to 4 billion. Your code happens to have values from 1 to n, but it can just as well be another case with value of 4 billion. So there needs to be some translation (IMO).

Waht happens to code like this

switch (RandomFunctionReturningValue1Through3Or4billion())
{ case 1 : statement;
case 2 : statement;
case 3 : statement;
case 4000000000 : statement;
}

Joe
Report TOU ViolationShare This Post
 Public ReplyPrvt ReplyMark as Last ReadFilePrevious 10Next 10PreviousNext