IN * IN is generally considered to be quadratic or polynomial, not exponential
do you mean that the code to implement the * operator is too large?
if sp. what operators do you have to work with?
could you do something like
OUT = IN
while( IN>>=1 ){ OUT <<= 1; }
or would that be too long also?
Main Topics
Browse All Topics





by: lbertaccoPosted on 2008-12-13 at 13:22:57ID: 23165501
Can you explain why OUT=IN*IN is not ok? What do you mean with "the binary gets too large"? 255*255 yields 65025 which does fit into 2 bytes.