Skip to content

Commit 1d2259a

Browse files
Merge branch 'master' into Replace-wrong-quotation-sign-with-the-correct-one
2 parents b065de6 + 74da412 commit 1d2259a

File tree

107 files changed

+526
-543
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

107 files changed

+526
-543
lines changed

CHANGELOG.md

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,15 +48,83 @@ Types of change:
4848

4949
### Fixed
5050

51+
52+
## January 24th 2022
53+
54+
### Changed
55+
- [Go - For Loops - Make the question fill in the gap only](https://github.com/enkidevs/curriculum/pull/3030)
56+
57+
### Fixed
58+
- [HTML - List Orders - Remove extra answer field from RQ](https://github.com/enkidevs/curriculum/pull/3031)
59+
60+
## January 10th 2022
61+
62+
### Fixed
63+
- [Python - Set Comprehension - More corrent answer to appropriate place in RQ](https://github.com/enkidevs/curriculum/pull/2987)
64+
65+
## January 9th 2022
66+
67+
### Changed
68+
- [Go - Go Packages - Remove type in the gap from PQ](https://github.com/enkidevs/curriculum/pull/2986)
69+
70+
## January 5th 2022
71+
72+
### Fixed
73+
- [HTML - Image Base - Add mising example using OpenGraph meta tag](https://github.com/enkidevs/curriculum/pull/2984)
74+
- [Git - Move The Last Commit To A New Branch - Add missing answer fields and improve wording of PQ](https://github.com/enkidevs/curriculum/pull/2983)
75+
- [Java - Multithreading Use Local Variables - Fix example](https://github.com/enkidevs/curriculum/pull/2982)
76+
77+
### Changed
78+
- [Html - Link Relative Paths - Change part of PQ as it wasn't worder properly](https://github.com/enkidevs/curriculum/pull/2985)
79+
- [Python - Format Text Paragraphs With Textwrap - Make the fill method more clear](https://github.com/enkidevs/curriculum/pull/2981)
80+
- [Python - Playing With Time - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3007)
81+
- [Python - Deep Into Collections - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/2997)
82+
- [Python - Python Functions - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3008)
83+
- [Python - Control Flow II - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/2996)
84+
- [Python - Control Flow I - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/2995)
85+
- [Python - Intro To Modules - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/2998)
86+
- [Python - Classes II - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/2993)
87+
- [Python - More On Dictionaries - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3004)
88+
- [Python - Math Recipies - Minor grammar improvement](https://github.com/enkidevs/curriculum/pull/3001)
89+
- [Python - More On Lists - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3005)
90+
- [Python - Classes I - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/2992)
91+
- [Python - Looping - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3000)
92+
- [Python - Meet Python - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3003)
93+
- [Python - Python Tips - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3010)
94+
- [Python - Sequential Data Types II - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3012)
95+
- [Python - Decorators - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3023)
96+
- [Python - Functional Programming II - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3025)
97+
- [Python - String Recipes - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3013)
98+
- [Python - Syntax And Numerical Operators - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3014)
99+
- [Python - Testing - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3015)
100+
- [Python - Unordered Data Types - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3016)
101+
- [Python - Utilities I - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3017)
102+
- [Python - Utilities II - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3018)
103+
- [Python - Working With Strings - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3019)
104+
- [Python - Arrays I - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3020)
105+
- [Python - Arrays II - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3021)
106+
- [Python - Comprehension - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3022)
107+
- [Python - Functional Programming - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3024)
108+
- [Python - Generators - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3026)
109+
- [Python - Python Immutability - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3028)
110+
- [Python - Iterators - Move single-line commands to a single line, update indentation in codeblocks from 4 to 2 spaces](https://github.com/enkidevs/curriculum/pull/3027)
111+
51112
## January 4th 2022
52113

53114
### Fixed
54115
- [Multiple Topics - Multiple insights - Replace all occurances of "wrong" quotations that break the "solve this question" feature with normal quotations](https://github.com/enkidevs/curriculum/pull/2977)
116+
- [HTML - Image Map - Fix incorrect description word for area element](https://github.com/enkidevs/curriculum/pull/2975)
117+
- [Blockchain - What Are Smart Contracts - Fix misspelled files word](https://github.com/enkidevs/curriculum/pull/2978)
55118
- [Linux - Converting Between Unix And Windows Text Files - Replace wrong quotation character with the correct one](https://github.com/enkidevs/curriculum/pull/2976)
56119

57120
## December 30th 2021
58121

122+
### Fixed
123+
- [HTML - The Caption Element - Add minor info when to use strong, b and font-weight property to avoid confusion](https://github.com/enkidevs/curriculum/pull/2972)
124+
59125
### Changed
126+
- [SQL - Join Role - Change table example](https://github.com/enkidevs/curriculum/pull/2973)
127+
60128
- [Git - All Applicable Code Blocks - Change all single line commands that span multiple lines from PQ and RQ & content to be on a single line.](https://github.com/enkidevs/curriculum/pull/2974)
61129

62130
## December 29th 2021

blockchain/blockchain-fundamentals/ethereum-i/what-are-smart-contracts.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ What do you have to pay for to publish a smart contract on the blockchain?
7676

7777
## Revision
7878

79-
What is the difference between a smart contract and code filles written in other languages?
79+
What is the difference between a smart contract and code files written in other languages?
8080

8181
???
8282

git/workflow/branches/move-the-last-commit-to-a-new-branch.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,11 +49,14 @@ git commit -m 'fixed'
4949

5050
## Practice
5151

52-
Run the commands in the correct order such that the last commit from current branch is moved to branch `bug-fix`:
52+
Run the commands in the correct order such that the last commit from current branch is moved to a new branch called `bug-fix`:
5353

5454
```plain-text
5555
???
5656
???
57+
???
58+
???
59+
???
5760
```
5861

5962
- `git reset HEAD~`

go/go-introduction/for-and-switch/go-for-loops.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ category: how-to
55
practiceQuestion:
66
formats:
77
- fill-in-the-gap
8-
- type-in-the-gap
98
context: standalone
109
revisionQuestion:
1110
formats:

go/go-introduction/go-introduction/go-packages.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ category: must-know
55
practiceQuestion:
66
formats:
77
- fill-in-the-gap
8-
- type-in-the-gap
98
context: standalone
109
revisionQuestion:
1110
formats:
@@ -90,9 +89,7 @@ import (
9089
)
9190
```
9291

93-
```plain-text
9492
???
95-
```
9693

9794
- B
9895
- A

java/threading/multithreading/multithreading-use-local-variables.md

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,19 +29,24 @@ private static List list =
2929
new ArrayList());
3030
@Override
3131
public void method(String input){
32-
// prefer this:
33-
List list = new ArrayList();
3432
list.add(input);
3533
list.clear();
3634
}
3735
```
3836

39-
In the example above, we attempt to save memory by reusing `list` and clearing it at the end of each call to `method()`.
37+
In the example above, we attempt to save memory by reusing list and clearing it at the end of each call to method().
4038

4139
However if we have multiple interleaved method calls, then they will be sharing access to `list`. This means that the input from one method call will be visible to a separate method call. The list might also be cleared by one while another is still using it.
4240

4341
We can solve this problem by declaring list as a local variable inside `method()` instead. This will use more memory, but guarantee that interleaved method calls do not interfere with each-other's lists.
4442

43+
```java
44+
public void method(String input){
45+
// prefer this:
46+
List list = new ArrayList();
47+
list.add(input);
48+
}
49+
```
4550

4651
---
4752

python/functional-programming/arrays-i/the-reversed-built-in-function.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,15 +31,15 @@ The `reversed` built-in allows us to create an iterator for an iterable sequence
3131
reversed(seq)
3232
```
3333

34-
Where `seq` is an iterable sequence such as a tuple, list, string or range. This returns an iterator which accesses the elements in the sequence in the reverse order. For example, we may use `reversed` to reverse the order of characters in a string.
34+
Where `seq` is an iterable sequence such as a tuple, list, string, or range. This returns an iterator, which accesses the elements in the sequence in the reverse order. For example, we may use `reversed` to reverse the order of characters in a string.
3535

3636
```python
3737
ourString = 'enki'
3838
print(list(reversed(ourString)))
3939
# Result: ['i', 'k', 'n', 'e']
4040
```
4141

42-
Notice how we could create custom classes that implement the `__reversed__()` method and then use `reversed` on them to quickly and efficiently reverse their ordering. In this way we can begin to see how often the `reversed` function might be useful in day-to-day programming tasks.
42+
Notice how we could create custom classes that implement the `__reversed__()` method and then use `reversed` on them to quickly and efficiently reverse their ordering. In this way, we can begin to see how often the `reversed` function might be useful in day-to-day programming tasks.
4343

4444

4545
---

python/functional-programming/arrays-i/the-slice-built-in-function.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,8 +105,7 @@ print(ourString[sObject])
105105
Use `slice` to remove every second number in the list of numbers.
106106

107107
```python
108-
nList = ['1', '2', '3', '4', '5',
109-
'6', '7', '8']
108+
nList = ['1', '2', '3', '4', '5', '6', '7', '8']
110109

111110
sObject = ???(???, ???, ???)
112111
print(nList[sObject])

python/functional-programming/arrays-i/the-zip-built-in-function.md

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -105,18 +105,9 @@ We have three lists, `fnames`, `lnames`, `locations`, which are ordered so that
105105
Fill in the gaps in the code below to achieve this.
106106

107107
```python
108-
locations = ['IT',
109-
'FR',
110-
'FR',
111-
'RU']
112-
fnames = ['italo',
113-
'jean',
114-
'emily',
115-
'katya']
116-
lnames = ['calvino',
117-
'micheal',
118-
'rambert',
119-
'sokolov']
108+
locations = ['IT', 'FR', 'FR', 'RU']
109+
fnames = ['italo', 'jean', 'emily', 'katya']
110+
lnames = ['calvino', 'micheal', 'rambert', 'sokolov']
120111

121112
result = zip(???, ???)
122113
result2 = zip(???, ???)

python/functional-programming/arrays-ii/the-map-built-in-function.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ revisionQuestion:
2929

3030
## Content
3131

32-
The `map` function is built in to the Python language. Together with the other built-in functions `filter` and `reduce`, `map` allows us to take a functional approach to programming in Python.
32+
The `map` function is built into the Python language. Together with the other built-in functions `filter` and `reduce`, `map` allows us to take a functional approach to programming in Python.
3333

3434
`map` applies a given function—`function_here` in the case below—iteratively to all items in a given `input_list`[1]. The basic syntax looks like this:
3535

@@ -68,8 +68,7 @@ Finally, it's good to know that we can pass more than one iterable `input_list`
6868
Let's say we have a list, called `promises`. We want to `make_good` on all our promises, where `make_good` is a previously-defined function that takes a string. Fill in the blanks in the code below to apply `make_good` to all elements in `promises`.
6969

7070
```python
71-
promises = ['learn css', 'learn js',
72-
'buy milk', 'be excellent to each other']
71+
promises = ['learn css', 'learn js', 'buy milk', 'be excellent to each other']
7372
promises = ???(???, ???)
7473
```
7574

python/functional-programming/arrays-ii/the-sorted-built-in-function.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,8 +105,7 @@ print(sorted([4, 0, 2, 3, 1, 5]))
105105
What is the result of the execution of the following code snippet?
106106

107107
```python
108-
print(sorted([0, 2, 3, 1,
109-
'a', 'b', 'A', 'B']))
108+
print(sorted([0, 2, 3, 1, 'a', 'b', 'A', 'B']))
110109
```
111110

112111
???

python/functional-programming/comprehension/dictionary-comprehension.md

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -34,11 +34,11 @@ cube_dict = {x: x ** 3 for x in num_list}
3434

3535
```
3636

37-
Now if we print cube_dict, we get:
37+
Now, if we print `cube_dict`, we get:
3838

3939
```python
4040
for k, v in cube_dict.items():
41-
print(k, v)
41+
print(k, v)
4242
# output
4343
# 1 1
4444
# 2 8
@@ -58,17 +58,18 @@ print(lcase_freqs)
5858
# partial output ...
5959

6060
{'u': 0, 'q': 0, 'w': 0, 'o': 0, \
61-
'b': 0, 'c': 0, 't': 0, 'h': 0, \
61+
'b': 0, 'c': 0, 't': 0, 'h': 0, \
6262
...
63-
'g': 0, 'a': 0, 'n': 0}
63+
'g': 0, 'a': 0, 'n': 0}
64+
6465
# Check it is correct:
6566
lfk = list(lcase_freqs.keys())
6667
lfk.sort()
6768
print(lfk)
6869
['a', 'b', 'c', 'd', 'e', 'f', \
69-
'g', 'h', 'i', 'j', 'k', 'l', \
70-
'm', 'n', 'o', 'p','q', 'r', \
71-
's', 't', 'u', 'v', 'w', 'x', \
72-
'y', 'z']
70+
'g', 'h', 'i', 'j', 'k', 'l', \
71+
'm', 'n', 'o', 'p','q', 'r', \
72+
's', 't', 'u', 'v', 'w', 'x', \
73+
'y', 'z']
7374

7475
```

python/functional-programming/comprehension/list-comprehension.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,7 @@ Use list comprehension to add one and divide by two [(x + 1) / 2] for all elemen
9797

9898
```python
9999
l = [1,2,3,4,5]
100-
x = [((x+1)/2) ??? x % 2 \
101-
??? x ??? x in ???]
100+
x = [((x+1)/2) ??? x % 2 ??? x ??? x in ???]
102101
```
103102

104103
- if

python/functional-programming/comprehension/nested-lists-comprehension.md

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -27,27 +27,23 @@ Since a list comprehension can take any **expression** as its initial expression
2727
These are often useful, but are often used to work with matrices.
2828

2929
```python
30-
matrix = [[1, 2, 3], [4, 5, 6], \
31-
[7, 8, 9]]
32-
30+
matrix = [[1, 2, 3], [4, 5, 6], [7, 8, 9]]
3331
```
3432

3533
Say we want to create another matrix with values equal to the squares of each element in the original matrix:
3634

3735
```python
38-
matrix2 = [[x**2 for x in row] for \
39-
row in matrix]
40-
#matrix2 = [[1, 4, 9], [16, 25, 36],\
41-
# [49, 64, 81]]
36+
matrix2 = [[x**2 for x in row] for row in matrix]
37+
#matrix2 = [[1, 4, 9], [16, 25, 36], [49, 64, 81]]
4238
```
4339

4440
A more advanced list comprehension with two for clauses and two if clauses:
4541

4642
```python
4743
lc = [ (x, y) for x in \
48-
range(10) if x % 2 == 0 \
49-
for y in range(20) if \
50-
y % 3 == 0 ]
44+
range(10) if x % 2 == 0 \
45+
for y in range(20) if \
46+
y % 3 == 0 ]
5147
# lc
5248
# [(0, 0), (0, 3), (0, 6), \
5349
# (0, 9), (0, 12), (0, 15), (0, 18),\
@@ -70,7 +66,6 @@ Use nested list comprehension to generate a list of tuples, where the first elem
7066
Ex: (1,1),(1,2),(1,3),...(9,7),(9,8),(9,9).
7167

7268
```python
73-
7469
l = [??? for x in range(10)\
7570
if ??? for y in ???]
7671
```

python/functional-programming/comprehension/set-comprehension.md

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -33,22 +33,19 @@ Imagine we have the following list:
3333

3434
```python
3535
my_list = [1, 2, 3, 4, 5, 6, 7, 8]
36-
3736
```
3837

3938
And we need a set containing only even numbers in the list. This can be easily achieved with **set comprehension**:
4039

4140
```python
4241
even_set = {x for x in my_list if x%2 == 0}
43-
4442
```
4543

4644
We can now check the result:
4745

4846
```python
4947
print(even_set)
5048
# {8, 2, 4, 6}
51-
5249
```
5350

5451
Note that the above operation would work even if my_list contained some duplicate values, e.g:
@@ -67,10 +64,8 @@ since sets by definition do not allow duplicates.
6764
Fill in the following code snippet. It creates a new set that contains elements of list `l` that are even and adds one and divides by two the odd numbers:
6865

6966
```python
70-
7167
l = [10, 11, 13, 14, 18, 19]
72-
new_set = {x ??? x % 2 == 0 else/
73-
??? for x ??? l}
68+
new_set = {x ??? x % 2 == 0 else ??? for x ??? l}
7469
```
7570

7671
- if
@@ -88,15 +83,14 @@ new_set = {x ??? x % 2 == 0 else/
8883
What will the `odd_set` look like after we run the following code snippet?
8984

9085
```python
91-
9286
l = [1,3,3,2,4,5,5,8,9]
9387
odd_set = {x for x in l if x % 2}
9488
```
9589

9690
???
9791

98-
- {1,3,3,5,5,9}
9992
- {1,3,5,9}
93+
- {1,3,3,5,5,9}
10094
- {1,2,3,4,5,8,9}
10195
- {2,4,8}
10296

0 commit comments

Comments
 (0)