title: Convert data frame to a list, with function from apply family
body: <p>Like in title i need to converte some data frame</p>
  <pre><code>data1 &lt;- data.frame(Year = rep(c(2016, 2017, 2018, 2019), each = 12), Month = rep(month.abb, 4), Expenses = sample(50e3:100e3, 48))
  </code></pre>
  <p>Create a list year_y in which  each year (element) contains a data frame with expenses in each month. Then using list year_y create a list containing for each year(element) the month with biggest expenses. Here is what the final result should look like:</p>
  <pre><code>$‘2016‘
  [1] &quot;Jul&quot;
  
  $‘2017‘
  [1] &quot;Nov&quot;
  
  $‘2018‘
  [1] &quot;May&quot;
  
  $‘2018‘
  [1] &quot;May&quot;
  </code></pre>
  <p>And the thing is i need to use apply function family in both steps</p>