```
<div>
  <ul> 
     <% if @subjects.present? %> 
        <%= @subjects.each do |subject| %>
           <li>
              <%= subject.name %>
           </li>
        <% end %>
     <% end %>
  </ul>
</div>

```

[This is the screenshot of the output.](http://i.stack.imgur.com/pzSmY.png)