Eighteenth Python exercise