Skip to content

Commit 47ac28f

Browse files
committed
10.1-19 README´s were changed
1 parent ea0316f commit 47ac28f

File tree

24 files changed

+146
-148
lines changed

24 files changed

+146
-148
lines changed
Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,19 @@
1-
# `10.1` Creando tu primera función
2-
1+
# `10.1` Creating Your First Function
32

43
## 📝 Instrucciones:
54

65
1. La función `add_numbers` debería devolver la suma de 2 números dados. Por favor, completa el código necesario dentro de la función para hacer que se comporte como se espera.
76

8-
## Resultado esperado:
9-
10-
El ejercicio debería escribir el número 7 en la cónsola.
7+
2. Resultado esperado: el ejercicio debería escribir el número 7 en la cónsola.
118

129
## 💡 Pista:
1310

1411
+ Hay una función `add_numbers` ya declarada, que está recibiendo dos parámetros
1512
(las variables `a` y `b`). Tú debes completar el contenido de la función con el código requerido para sumar la variable `a` con la variable `b` y devolver el resultado de la operación.
1613

17-
## :mag_right: Importante:
18-
19-
+ Para practicar con más funciones, 4Geeks Academy tiene más de 20 ejercicios que incrementan en dificultad [aquí](https://github.com/4GeeksAcademy/python-functions-programming-exercises),
20-
(luego..¡Regresa! :smiley:).
14+
## 🔎 Importante:
2115

16+
+ Para practicar con más funciones, 4Geeks Academy tiene más de 20 ejercicios que se incrementan en dificultad: [https://github.com/4GeeksAcademy/python-functions-programming-exercises](https://github.com/4GeeksAcademy/python-functions-programming-exercises).
2217

18+
¡Inténtalos, y luego regresa!😃
2319

exercises/10.1-Creating-Your-First-Function/README.md

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,7 @@ tutorial: "https://www.youtube.com/watch?v=K0aDrl41SnQ"
99
1. The function `add_numbers` is supposed to return the sum of 2 given numbers, please
1010
complete the needed code inside of the function to make it behave as expected.
1111

12-
## Expected Result:
13-
14-
The exercise should print the number 7 in the console.
12+
2. Expected Result: the exercise should print the number 7 in the console.
1513

1614
## 💡 Hint:
1715

@@ -20,9 +18,8 @@ The exercise should print the number 7 in the console.
2018
function content with the code needed to sum variable `a` with variable `b` and
2119
return the result of that operation.
2220

23-
## :mag_right: Important:
24-
25-
For practicing more with functions, 4Geeks Academy has more than 20 incremental exercises [here](https://github.com/4GeeksAcademy/python-functions-programming-exercises).
26-
You should those first and then....come back! :smiley:
21+
## 🔎 Important:
2722

23+
For practicing with more functions, 4Geeks Academy has more than 20 exercises that increase in difficulty: [https://github.com/4GeeksAcademy/python-functions-programming-exercises](https://github.com/4GeeksAcademy/python-functions-programming-exercises).
2824

25+
Try them, and then come back!😃
Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,16 @@
1-
# `11` Crear una nueva función
1+
# `11` Create a New Function
22

3-
Como sabes, las funciones son un bloque de código útil que puedes reutilizar tantas veces como necesites o quieras. En el último ejercicio, tenías una función que recibía dos parámetros
3+
Como sabes, las funciones son un bloque de código útil que puedes reusar tantas veces como necesites.
4+
5+
En el último ejercicio, tenías una función que recibía dos parámetros
46
(dos entradas) y devolvía la suma de ellos. Así:
57

68
```py
79
def add_numbers(a, b):
810
print(a + b)
911
```
1012

11-
Pero Python viene con un conjunto de funciones "pre-definidas" que puedas usar, por ejemplo:
13+
Pero Python viene con un conjunto de funciones "pre-definidas" que puedes usar, por ejemplo:
1214

1315
```py
1416
import random
@@ -18,20 +20,20 @@ r1 = random.randint(0, 10)
1820
print("Random number between 0 and 10 is % s" % (r1))
1921
```
2022

21-
Puedes usar la función `randint()` para obtener un número decimal aleatorio. `Randint()` es una función incorporada del módulo **random** en Python3.
22-
El **módulo random** te da acceso a varias funciones útiles y una de ellas, `randint()`. es capaz de generar números aleatorios,
23+
Puedes usar la función `randint()` para obtener un número decimal aleatorio. Esta es una función incorporada del **módulo random** en Python3.
24+
25+
El **módulo random** te da acceso a varias funciones útiles y una de ellas es, `randint()`, capaz de generar números aleatorios.
2326

2427
## 📝 Instrucciones:
2528

26-
1. Por favor, ahora, crea una función llamada `generate_random` que imprima Y devuelva un número
27-
aleatorio entre 0 y 9 cada vez que le llame.
29+
1. Por favor, ahora crea una función llamada `generate_random` que imprima y devuelva un número aleatorio entre 0 y 9 cada vez que le llame.
2830

2931
## 💡 Pista:
3032

31-
- Una posible solución involucra el uso de dos funciones predefinidas: las funciones `randint` o `randrange`.
33+
+ Una posible solución involucra el uso de dos funciones predefinidas: las funciones `randint` o `randrange`.
3234

33-
- No olvides importar el **módulo random**.
35+
+ No olvides importar el **módulo random**.
3436

35-
- Puedes consultar la documentación en: https://docs.python.org/3/library/random.html#functions-for-integers
37+
+ Puedes consultar la documentación en: https://docs.python.org/3/library/random.html#functions-for-integers
3638

3739

exercises/11-Create-A-New-Function/README.md

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,11 @@ tutorial: "https://www.youtube.com/watch?v=XazswkTqKJI"
44

55
# `11` Create a New Function
66

7-
As you know, functions are a useful block of code that you can re-use as many times as you need or want. In the last exercise, you had a function that received two parameters (two inputs) and returned the sum of those. Like this:
7+
As you know, functions are a useful block of code that you can re-use as many times as you need. In the last exercise, you had a function that received two parameters (two inputs) and returned the sum of those. Like this:
88

99
```py
1010
def add_numbers(a, b):
1111
print(a + b)
12-
13-
1412
```
1513

1614
But Python comes with a bunch of "pre-defined" functions that you can use, for example:
@@ -23,19 +21,20 @@ r1 = random.randint(0, 10)
2321
print("Random number between 0 and 10 is % s" % (r1))
2422
```
2523

26-
You can use the `randint()` function to get a random decimal number. `Randint()` is an inbuilt function of the **random module** in Python3. The random module gives access to various useful functions and one of them being able to generate random numbers, which is `randint()`.
24+
You can use the `randint()` function to get a random decimal number. `Randint()` is an inbuilt function of the **random module** in Python3.
25+
26+
The **random module** gives access to various useful functions and one of them being able to generate random numbers, which is `randint()`.
2727

2828
## 📝 Instructions:
2929

30-
1. Please now create a function called `generate_random` that prints AND returns a random number
31-
between 0 and 9 every time it is called.
30+
1. Please now create a function called `generate_random` that prints and returns a random number between 0 and 9 every time it is called.
3231

3332
## 💡 Hint:
3433

35-
- One possible solution involves using two predefined functions: the `randint()` or `randrange()` function.
34+
+ One possible solution involves using two predefined functions: the `randint()` or `randrange()` function.
3635

37-
- Don't forget to import the **random module**.
36+
+ Don't forget to import the **random module**.
3837

39-
- Check the documentation: https://docs.python.org/3/library/random.html#functions-for-integers
38+
+ You can check the documentation here: https://docs.python.org/3/library/random.html#functions-for-integers
4039

4140

exercises/12-Rand-From-One-to-Six/README.es.md

Lines changed: 0 additions & 15 deletions
This file was deleted.

exercises/12-Rand-From-One-to-Six/README.md

Lines changed: 0 additions & 18 deletions
This file was deleted.
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# `12` Rand From One to Twelve
2+
3+
## 📝 Instrucciones:
4+
5+
1. Cambia lo que necesites cambiar para hacer que el algoritmo imprima números enteros aleatorios entre 1 y 12.
6+
7+
2. Esta vez, utiliza la función `randrange()`.
8+
9+
## 💡 Pista:
10+
11+
+ Debería imprimir números entre 1 y 12, no entre 0 y 12.
12+
13+
+ Este ejercicio es super simple, no te compliques!😃
14+
15+
16+
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
---
2+
tutorial: "https://www.youtube.com/watch?v=EdyMlVlNUT0"
3+
---
4+
5+
# `12` Rand From One to Twelve
6+
7+
## 📝 Instructions:
8+
9+
1. Change whatever you need to change to make the algorithm print random integers between 1 and 12.
10+
11+
2. This time use `randrange()`function.
12+
13+
## 💡 Hint:
14+
15+
+ It should print between 1 and 12, not between 0 and 12.
16+
17+
+ This exercise is super simple, don't complicate yourself!😃
18+
19+
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)