MySQL Basics In Pictures
  1. Type:

    SELECT COUNT(age),AVG(age) FROM name;

    then press ENTER.

    The query results should look like this:

    This query does two things:
    • COUNT the number of presidents in the name table.
    • Calculate the AVG (average) age of these presidents when they took office.