Hi,

<% source.strains.each_with_index do |strain, j| %>
 <% if (j == (source.strains.size - 1)) %>
  <font size="3">Strain <%= strain[0].appendix %> </font>
 <% end %>
<% end %>

I need to get output as

If j value is last one of a loop, then i need to print first value of loop
(j[0]). Kindly suggest me or correct above script.
-- 
With Regards and Thanks,
Palani Kannan. K,

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to