That's exactly what I was thinking of - so now, how to implement in picbasic!
Imagine an array 100 deep (& for simplicity's sake, populated with values 1 thru 100), with an incoming number of 90 to 'look up' against...
So, the methodology....
is new incoming value higher or lower than 50
(result = higher therefore the next stage...)
is new incoming number higher of lower than 75
result = higher again, & so on it continues...
but eventually it all starts getting tricky (because half way between 75 & 100 is 87.5 ....what to do here, etc?)
Bookmarks