title: Avg value using subquery
body: <p>I want to make a query that gives me the max and min average mark of students. I can get the max and min marks, but I don't know how to caluclate average of those.</p>
  
  <pre><code>SELECT MAX(mark) AS Max_mark FROM passed 
  GROUP BY student_id;
  </code></pre>
  
  <p>This gives the max mark from every student, I need average of that values.</p>