From: Charles Mills Date: 2004-09-24T07:09:25+09:00 Subject: Re: Newbie: Case statement On Sep 23, 2004, at 2:34 PM, Warren Brown wrote: > Graham, > > You can save yourself an enormous number of headaches by simply > adding two more rows and columns to your array. For example, if you > wanted the world to be 80x24, make your array 82x26 and then make your > loops from 1..80 and 1..24. That way you can safely reference > cell[x-1][y-1] and cell[x+1][y+1] and you don't need all of your > special > cases. > > - Warren Brown > The 1 dimensional version of what you just described is how sqlite stores each row header. An array of num_fields+1 offsets where the last offset is the record length. Pretty handy concept. -Charlie