{
"metadata": {
"name": "ExercisesI"
},
"nbformat": 3,
"nbformat_minor": 0,
"worksheets": [
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"[Python for Developers](http://ricardoduarte.github.io/python-for-developers/#content)\n",
"===================================\n",
"First Edition\n",
"-----------------------------------\n",
"\n",
"Exercises I\n",
"=============================\n",
"_____________________________\n",
"1\\. Implement the two functions:\n",
"\n",
"+ One that converts temperature in degrees *Celsius* to degrees *Fahrenheit*.\n",
"+ Anthoer that converts temperature in degrees *Fahrenheit* to degrees *Celsius*.\n",
"\n",
"Keep in mind that:\n",
"\n",
"$$F = \\frac{9}{5} \\cdot C + 32$$\n",
"\n",
"2\\. Implement a function that returns true if the number is prime (false otherwise). Test from 1 to 100.\n",
"\n",
"3\\. Implement a function that takes a list of lists of any length and returns a list of one dimension.\n",
"\n",
"4\\. Implement a function that takes a dictionary and returns the sum, average and range of its values\u200b\u200b.\n",
"\n",
"5\\. Write a function that:\n",
"Gets a phrase as a parameter.\n",
"Returns a new sentence with each word with the letters reversed.\n",
"\n",
"6\\. Create a function that:\n",
"\n",
"+ Gets a list of tuples (data), an integer (key, by default equal to zero) and a boolean (reverse, false by default).\n",
"+ Returns data sorted by item indicated by key in descending order and if reverse is true."
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [],
"language": "python",
"metadata": {},
"outputs": [
{
"html": [
"\n",
""
],
"output_type": "pyout",
"prompt_number": 1,
"text": [
""
]
}
],
"prompt_number": 1
}
],
"metadata": {}
}
]
}