"includeName": true,
"pageSize": "A4",
"landscape": false,
- "margin": "0",
- "downscalePercent": 80
+ "margin": "2",
+ "downscalePercent": 67
},
"promptDelete": false,
"openBehavior": "file:List of things to do",
"interfaceFontFamily": "Courier Code",
"textFontFamily": "Courier Code",
"monospaceFontFamily": "Courier Code",
- "cssTheme": "Obsidian gruvbox"
+ "cssTheme": "Sanctum"
}
\ No newline at end of file
"type": "tabs",
"children": [
{
- "id": "d2b9d46d83ae4703",
+ "id": "1598ee3eb0962476",
"type": "leaf",
"state": {
"type": "markdown",
"state": {
- "file": "WP and Flamethrowers/Apparently White Phosphorus and Flamethrowers are not illegal under international law.md",
+ "file": "Watchlist & Do List.md",
"mode": "source",
"source": false,
"backlinks": true,
}
},
"icon": "lucide-file",
- "title": "Apparently White Phosphorus and Flamethrowers are not illegal under international law"
+ "title": "Watchlist & Do List"
}
}
]
"pdf-plus:PDF++: Toggle auto-paste": false
}
},
- "active": "d2b9d46d83ae4703",
+ "active": "1598ee3eb0962476",
"lastOpenFiles": [
+ "List of things to do.md",
+ "DGG Hackathon Simple Cheatsheet.md",
"WP and Flamethrowers/Apparently White Phosphorus and Flamethrowers are not illegal under international law.md",
"WP and Flamethrowers",
"Nebulous Command/Missile Interception/Det. vs. Intc. vs. Saturation.md",
- "List of things to do.md",
"Nebulous Command/Missile Interception/Data.md",
"Nebulous Command/Missile Interception/Effective Defense Layouts.md",
"Nebulous Command/Missile Interception/Test Layouts/SCC_SGM211_Layout.png",
"European Union/Child Sexual Abuse Act/Notes on the Original Document.md",
"European Union/Child Sexual Abuse Act/cellar_13e33abf-d209-11ec-a95f-01aa75ed71a1.0001.02_DOC_1.pdf",
"Nebulous Command/Notes on Nebulous Command.md",
- "Nebulous Command/Notes on Mechanics.md",
"NoteOn/note-on-logo.png",
"NoteOn/note-on-500-oops.svg",
"NoteOn/note-on-404-not-found.svg",
--- /dev/null
+lambda functions and map function
+
+```python
+% # MOD operator
+// # Integer division Math.floor(a / b)
+
+def FUNCTION_NAME(arg1[: type], arg2[: type]):
+ # the indent is needed
+
+while CONDITION:
+ # indent
+
+for variable in ARRAY: # every item in array
+
+for index, variable in enumerate(ARRAY):
+
+# length of str or array
+a, b = len(STR), len(ARRAY)
+
+for index in range(len(ARRAY)):
+# range(ARRAY), creates a range of numbers
+# according to range(START, STOP, STEP)
+# STOP non-inclusive
+
+l = list(range(0, 5)) # may be cast to list
+# [0, 1, 2, 3, 4]
+
+if VAR in ARRAY:
+
+if VAR not in ARRAY:
+
+match var:
+ case PATTERN:
+ <action>
+ case _:
+ <default action>
+```
+### Arrays
+```python
+ARRAY.append(ELEMENT)
+ARRAY.count(ELEMENT)
+ARRAY.index(ELEMENT) # first index of element
+ARRAY.reverse()
+ARRAY[index] # indexing
+ARRAY[start:stop] # index, stop is not included
+ARRAY[start:stop:step] # slice with step
+# e.g. fast reverse: ARRAY[::-1] is ARRAY but reversed
+
+k = [var * 2 for var in ARRAY] # fast map
+k = [var * 2 if CONDITION for var in ARRAY]
+k = [var * 2 if CONDITION else var for var in ARRAY]
+```
+### String manipulation
+```python
+STRING.join(ARRAY)
+# e.g.
+# ",".join(["3", "5", "3"])
+# "3,5,3"
+
+STR = f"The value of this variable is {VAR}"
+STR = f"{VAR:.2f}" # limits to two decimal points
+
+INT = ord(CHAR) # ASCII value
+CHAR = chr(INT) # other way around
+ARRAY = STRING.split(CHAR)
+INT = STRING.find(SUBSTRING[, START, STOP]) # first occurence index
+INT = STRING.rfind(SUBSTRING[, START, STOP]) # first occurence index, but in reverse
+STRING.isdigit()
+STRING.isalpha() # i.e. alphabetic char > 1
+STR = STR.lower() # lowercase
+STR = STR.upper() # uppercase
+STR = STR.strip(STR of CHARS)
+STR = STR.replace(OLD, NEW)
+```
\ No newline at end of file
hannibal
frieren
+project hail mary
+
+play: death stranding
+
+listen: god is an astronaut
+
+watch: dark
+
+watch: ministry of ungentlemanly warfare
+
+watch: kingdom of heaven
+
+watch: the dark knight
+
+watch: kill bill
+
+watch: knight of the seven kingdoms
The family stone