There are lots of ways of doing this, but the easiest is probably:
$sql1 = "SELECT DISTINCT year FROM reports ORDER BY year DESC";
With DISTINCT
, the database will only return one of each value. Then you don't have to waste any resources processing data on the PHP side.