From: John Kaurin Date: 2001-04-10T12:40:14+09:00 Subject: [ruby-talk:13589] All In A Row? I thought I saw something like this in my early readings on Ruby, but I cannot find it now. Is there a Ruby method for arrays that will determine if all of the elements are in a sequence? Something like: [1, 2, 3, 4].sequence? -> true [1, 3, 4, 5].sequence? -> false ["a", "b", "c", "d"].sequence? -> true ["a", "c", "d", "e"].sequence? -> false Maybe extrapolated to take an argument: [1, 3, 5, 7].sequence?(2) -> true [1, 5, 7, 9].sequence?(2) -> false ["a", "c", "e", "g"].sequence?(2) -> true ["a", "e", "g", "i"].sequence?(2) -> false Thanks in advance.