File tree Expand file tree Collapse file tree 9 files changed +64
-0
lines changed Expand file tree Collapse file tree 9 files changed +64
-0
lines changed Original file line number Diff line number Diff line change 1
1
<p align =" center " ><img src =" images/python_exercises.png " /></p >
2
2
3
+ :information_source :   ; This repo contains questions and exercises to learn and practice Python
4
+
5
+ :bar_chart :   ; There are currently ** 49** exercises and questions
6
+
3
7
# Python Exercises
4
8
5
9
## Hello World
21
25
| Choose a Data Type - level 2 | [ Exercise] ( exercises/data_types/choose_datatype_level_2.md ) | [ Solution] ( solutions/data_types/choose_datatype_level_2.md ) | |
22
26
| Mutability | [ Exercise] ( exercises/data_types/mutability.md ) | [ Solution] ( solutions/data_types/mutability.md ) | |
23
27
| Strongly Typed | [ Exercise] ( exercises/data_types/strongly_typed.md ) | [ Solution] ( solutions/data_types/strongly_typed.md ) | |
28
+ | Object Creation | [ Exercise] ( exercises/data_types/object_creation.md ) | [ Solution] ( solutions/data_types/object_creation.md ) | |
24
29
25
30
## Variables
26
31
29
34
| Valid Names | [ Exercise] ( exercises/variables/valid_names.md ) | [ Solution] ( solutions/variables/valid_names.md ) | |
30
35
| Locations or Names | [ Exercise] ( exercises/variables/locations_or_names.md ) | [ Solution] ( solutions/variables/locations_or_names.md ) | |
31
36
| Types | [ Exercise] ( exercises/variables/types.md ) | [ Solution] ( solutions/variables/types.md ) | |
37
+ | Multiple Value Assignment | [ Exercise] ( exercises/variables/multiple_value_assigment.md ) | [ Solution] ( solutions/variables/multiple_value_assigment.md ) | |
32
38
33
39
## Booleans
34
40
Original file line number Diff line number Diff line change
1
+ ## Object Creation
2
+
3
+ 1 . Describe in detail what happens when the following code is executed: ` var = 3 `
4
+
5
+ ### Solution
6
+
7
+ Click [ here] ( solutions/data_types/object_creation.md ) to view the solution
Original file line number Diff line number Diff line change 1
1
## Python Characteristics
2
2
3
3
1 . What are some characteristics of the Python programming language?
4
+
5
+ Click here for the [ solution] ( solutions/hello_world/python_characteristics.md )
Original file line number Diff line number Diff line change 6
6
* ` 1 == 1 `
7
7
* ` 4 < 1 `
8
8
* ` 'two' > 1 `
9
+
10
+ Click here for the [ solution] ( solutions/hello_world/what_is_the_result_lvl_1.md )
Original file line number Diff line number Diff line change
1
+ ## Multiple Value Assignment
2
+
3
+ 1 . How can you write the following code differently but have the same result?
4
+
5
+ ```
6
+ a=1
7
+ b=1
8
+ c=1
9
+ ```
10
+
11
+ ### Solution
12
+
13
+ Click [ here] ( solutions/variables/multiple_value_assigment.md ) to view the solution
Original file line number Diff line number Diff line change
1
+ ## Types
2
+
3
+ 1 . How to check the type of a variable in Python?
4
+ 2 . How to check if a variable points to an object of an integer type?
5
+ 3 . How to check type of a literal?
Original file line number Diff line number Diff line change
1
+ #! /usr/bin/env bash
2
+
3
+ echo $(( $(grep - E "\[Exercise\]|</ summary> " - c README.md )) )
Original file line number Diff line number Diff line change
1
+ ## Object Creation
2
+
3
+ 1 . Describe in detail what happens when the following code is executed: ` var = 3 `
4
+
5
+ ### Solution
6
+
7
+ * An object of type integer is created with the value of 3.<br >
8
+ * The variable points ` var ` points to the created object<br >
9
+ * Reference count is incremented by 1
Original file line number Diff line number Diff line change
1
+ ## Multiple Value Assignment
2
+
3
+ 1 . How can you write the following code differently but have the same result?
4
+
5
+ ```
6
+ a=1
7
+ b=1
8
+ c=1
9
+ ```
10
+
11
+ ### Solution
12
+
13
+ 1 .
14
+
15
+ ```
16
+ a=b=c=1
17
+ ```
You can’t perform that action at this time.
0 commit comments