This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Userstyle for the the Mastodon web application | |
De-emphasizes the display name in favor of the | |
actual @username on , i.e. | |
┌──────────────────────────────┐ | |
│ ┌─────┐ │ | |
│ │ pfp │ @username@server │ larger font | |
│ │ │ Display Name │ smaller font |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# .idlerc/config-highlight.cfg | |
# Several dark color themes | |
[Tomorrow Night] | |
definition-foreground = #81a2be | |
error-foreground = #e37170 | |
normal-foreground = #c5c8c6 | |
keyword-foreground = #b294bb | |
hilite-foreground = #c5c8c6 | |
comment-background = #1d1f21 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# CSV was funktioniert | |
import pandas as pd | |
df = pd.read_csv("D:\Python\Vokabeltrainer\englisch.csv", | |
sep=";", | |
header=0, | |
#encoding = "latin1", sollte Umlaute anpaasen, aber zerstört sie | |
names=["Deutsch", | |
"Englisch"], | |
dtype = {"Deutsch":str, | |
"Englisch":str}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/python | |
# https://adventofcode.com/2020/day/9 | |
with open('day9.txt') as f: | |
heightmap = [list(map(int, line.strip())) for line in f] | |
H, W = len(heightmap), len(heightmap[0]) | |
COORDS = [(x, y) for y in range(H) for x in range(W)] | |
value_at = lambda p: heightmap[p[0]][p[1]] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/python | |
# solution for https://adventofcode.com/2021/day/5 | |
data = [] | |
with open('day5.txt') as f: | |
for line in f: | |
data.append([tuple(map(int, c.split(','))) for c in line.strip().split(' -> ')]) | |
def get_line_points(pair): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/python | |
with open('day1.txt') as f: | |
measurements = list(map(int, f)) | |
def compare(values): | |
return [m for i, m in enumerate(values) if i and m > values[i-1]] | |
print(f"Part One: {len(compare(measurements))}") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/python | |
class Submarine(): | |
def __init__(self): | |
self.horizontal = 0 | |
self.depth = 0 | |
self.aim = 0 | |
def forward(self, amount): | |
self.horizontal += amount | |
self.depth += amount * self.aim |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Available variables: | |
// - Machine | |
// - interpret | |
// - assign | |
// - send | |
// - sendParent | |
// - spawn | |
// - raise | |
// - actions |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
! Twitter element block rules, for use in uBlock Origin ------------------------- | |
! ads --------------------------------------------------------------------------- | |
twitter.com##div.suggested-tweet-stream-container | |
twitter.com##div.promoted-tweet | |
twitter.com##li.promoted-trend | |
twitter.com##div.Footer-adsModule | |
twitter.com##div.js-actionable-user.promoted-account | |
! timeline breakers ------------------------------------------------------------- | |
twitter.com##.js-stream-item[data-suggestion-json*='RecycledTweetInline'] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
! uMatrix: Ruleset recipes 1.0 | |
! Title: My various uBlock rulesets | |
! Maintainer: Tomalak | |
Vine.co Embeded Frames | |
* vine.co | |
_ vine.co image | |
_ vine.co css | |
_ vine.co script | |
_ vine.co frame |
NewerOlder