human
Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. 
###Database Schema: Code, Type, Name, Area (km 2 ), Population, Regional County Municipality, Region
###Question: What is the km2 area for the population of 311?
gpt
SELECT AVG Area (km 2 ) FROM table WHERE Population = 311