David A. Black wrote:
> Hi --
> 
> On Thu, 9 Jul 2009, Dipti Iyengar wrote:
> 
>> Any quicker way to do this?
> You could do:
> 
>    LEVELS = %w{ High Medium Low Info Safe }
> 
>    sorted = risks.sort_by {|r| LEVELS.index(r.capitalize) }
> 
> 
> David

Thanks a lot Bertram .... Worked like a charm....
Thanks a lot David...didn't try the solution as yet :)
-- 
Posted via http://www.ruby-forum.com/.