From: Xavier Noria Date: 2007-08-18T19:43:22+09:00 Subject: Re: How do you print the first 5 records in an array? On Aug 18, 2007, at 11:55 AM, Bob Sanders wrote: > @people = ["Jim", "Jen", "Jess", "Jay", "Jack", "John", "Jeff", "Jed", > "Jill"] > > How would I then print out the first 5 records of that array? (i.e. > from > Jim to Jack) You can explicitly say "Take n items starting from index i" with the syntax array[i, n] In your example that'd give puts @people[0, 5] -- fxn