Working on Rails and found lack of knowledge in my understanding of the each method.
Not sure why the each method requires the variable |message|
<% @messages.each do |message| %>
<h2><%= message.title %></h2>
<%= link_to "View Message", message_path(message), class: "btn btn-default" %>
<% end %>