Thank you guys for your answers. Ruby is my favourite language mostly because it is pure object oriented and above that you can incorporate functional programming which has it's advantages; smaller, clearer, less error prone code. "Haris Bogdanovic" <fbogdanovic / xnet.hr> wrote in message news:gk3m77$1ft$1 / gregory.bnet.hr... > Hi. > > I'm starting to learn functional programming with Ruby. > I would like for someone to write me an example of finding the smallest > number in the list and a sorting algorithm. > I got the concept of map (collect), filter (select, detect and reject) and > reduce (inject) higher order functions but I don't know how to compose > algorithms from them. > So please write me those two algorithms or some other simple ones with > some explanation. > Some links to this subject would be nice also. > > Thanks > Haris >