DrillSergeant, I added your tests #5 and #6 just to verify my code works as yours. It does but I do not seem to be able to trim very much at this time. I guess I need to ponder my approach and looping structure a little. Hopefully I can give you a little competition.

Running Test 1 Encoding...Decoding...Done
Running test 2 Encoding...Decoding...Done
Running Test 3 Encoding...Decoding...Done
Running Test 4 Encoding...Decoding...Done
Running Test 5 Encoding...Decoding...Done
Running Test 6 Encoding...Decoding...Done
Your solution passed all tests

KiXtart
KiXtart Version = 4.52
KiXGolf Script = kixgolf_ts.kix

Computer
OS = Windows XP Professional
CPU = Intel Pentium Model 13
Speed = 1798 MHz
Memory = 1024 MB

KiXGolf Scoring Engine
Scoring Engine = 3.3

KiXtart Golf Score
Tournament = Top Secret
Processing Start = 2007/08/07 10:16:25.996
Processing End = 2007/08/07 10:16:26.016
Duration = 0000/00/00 00:00:00.020
KiXGolf Score = 473

Thank you for participating in KiXtart Golf!
_________________________
Home page: http://www.kixhelp.com/hb/