A characteristic of an Object that indicates the ability to change its state after creation.
first-class citizen
an entity which supports all the operations generally available to other entities. These operations typically include being passed as a parameter, returned from a function, and assigned to a variable.
copy / paste
A text editor function that is used by programmers that want to lose their jobs, or have swore revenge against their future selves.
Neckbeard
A phenomena that happens to programmers when learning functional languages (Haskell).
Common functions
Core functions used when doing functional programming
for each
array = [1, 2, 3, 4]
for element in array:
print(element)
arr = [1, 2, 3, 4]
ind = 0
while ind < len(arr):
item = arr[ind]
print(item)
ind += 1
map
array = [1, 2, 3, 4]
result = map(str, array)
arr = [1, 2, 3, 4]
result = []
for item in arr:
str_object = str(item)
result.append(str_object)