From: Matt Beckley Date: 2009-10-25T11:57:37+09:00 Subject: using .delete_if and reject on elements in an array Working on code to fill an array with 200 random integer elements. The elements range from 1-100 in value. Next I use the .sort method to see how many values fall between 1-10 to visually check how many random numbers will fall between 1-10. Now I wanna take my array and apply a method to it that will check which elements are less 21 but more then 10. For you math types 1021} Heres what I have so far of my program: ******************************************************************************** nums = [] 200.times do nums << rand(100) end nums1 = nums.sort nums1.each {|n| print n, "," } ******************************************************************************** Please include the code so I can try it out on my editor and get it figured out! Thanks, Matt -- Posted via http://www.ruby-forum.com/.