Ruby/Array/select
Материал из Wiki.crossplatform.ru
(Различия между версиями)
				
	
		| ViGOur  (Обсуждение | вклад)  м  (1 версия: Импорт выборки материалов по Ruby) | 
Текущая версия на 18:01, 13 сентября 2010
Which of these numbers are less than the target?
ceiling = 50 p [1, 10, 49, 50.1, 200].select { |x| x < ceiling } # => [1, 10, 49]
