I believe the fastest way is an array of solutions indexed by the input=20 values. If you need faster than that, a hardware diode array will do it in one=20 machine cycle IF you can load the index that fast. On 1/17/2018 6:32 PM, Dwayne Reid wrote: > Was just wondering if there is another (faster) > method that works over the range of 0..2047 decimal or 0..511 decimal. --=20 John Ferrell W8CCW Julian NC 27283 It is better to walk alone, than with a crowd going the wrong direction. --Diane Grant --=20 http://www.piclist.com/techref/piclist PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist .