- 500 g stew meat (beef, chicken, or vegetarian alternatives such as tofu or Quorn)
- 2 tbsp olive oil
- 1 onion, chopped
- 2 cloves garlic, minced
- 2 carrots, sliced
- 2 celery stalks, sliced
- 1 red bell pepper, diced
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
#!/usr/bin/env python3 | |
import random | |
first = ['Aelric', 'Alaric', 'Aria', 'Asha', 'Ashe', 'Branwen', 'Bryn', 'Caelan', 'Caelwyn', 'Calliope', 'Cassian', 'Celine', 'Clover', 'Damaris', 'Dorian', 'Eadric', 'Eirian', 'Elior', 'Elliora', 'Elyra', 'Erasmus', 'Faelan', 'Fenna', 'Finn', 'Finnan', 'Fiora', 'Freya', 'Gideon', 'Gwydion', 'Halia', 'Isolde', 'Jareth', 'Jory', 'Kaelan', 'Kaelin', 'Lilith', 'Lorien', 'Lyanna', 'Lysander', 'Maelon', 'Mara', 'Niamh', 'Oisin', 'Oran', 'Orion', 'Pryderi', 'Quinlan', 'Reed', 'Rhiannon', 'Riven', 'Rowan', 'Saria', 'Sariel', 'Selene', 'Siona', 'Talia', 'Taran', 'Thalion', 'Tilly', 'Tobias', 'Urien', 'Vespera', 'Willow', 'Wynne', 'Xanthe', 'Yseult', 'Zariel', 'Zephyr'] | |
last1 = ['Barley', 'Blade', 'Brave', 'Bright', 'Brook', 'Dagger', 'Dew', 'Duel', 'Edge', 'Fable', 'Feather', 'Fire', 'Harp', 'Heart', 'Hearth', 'Iron', 'Light', 'Meadow', 'Myth', "O'", 'Oak', 'Quick', 'Quill', 'Rhyme', 'Rune', 'Sable', 'Scroll', 'Shield', 'Song', 'Spin', 'Stal', 'Steel', 'Story', 'Strong', 'Sweet |
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
#!/usr/bin/env python3 | |
import re | |
import sys | |
def visible_length(s): | |
# Remove ANSI escape sequences | |
ansi_escape = re.compile(r'\x1b\[[0-9;]*[mK]') | |
stripped = ansi_escape.sub('', s) | |
return len(stripped) |
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
# Created by ChatGPT 4.0o, untested | |
SRC_DIR := . | |
BUILD_DIR := public_html | |
DEST_DIR := /path/to/production | |
SERVER := [email protected] | |
MD_FILES := $(wildcard $(SRC_DIR)/*.md) | |
HTML_FILES := $(MD_FILES:$(SRC_DIR)/%.md=$(BUILD_DIR)/%.html) | |
# Rule to convert markdown to HTML |
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
SRC_DIR := . | |
# TODO: Change DEST_DIR and SERVER to match your site | |
DEST_DIR := /var/www/production | |
SERVER := [email protected] | |
HTML_FILES := $(wildcard $(SRC_DIR)/*.html) | |
PHP_FILES := $(wildcard $(SRC_DIR)/*.php) | |
FILES := $(HTML_FILES) $(PHP_FILES) |
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
# (män, kvinnor), 5-årsintervaller, källa: | |
# https://www.scb.se/hitta-statistik/sverige-i-siffror/manniskorna-i-sverige/befolkningspyramid-for-sverige/ | |
a = [(296183, 280184), (319820, 301335), (325003, 306568), (310539, 292308), (310354, 275136), (342974, 323678), (400939, 379866), (357035, 337476), (331475, 316375), (332100, 320776), (334354, 326130), (344012, 334707), (288783, 286309), (268962, 273778), (255190, 269193), (238376, 259291), (140775, 167556), (69776, 102177), (25990, 52397), (5259, 15730), (425, 2262)] | |
totalt = sum(map(sum, a)) | |
# 6 första intervallerna är 0-4, 5-9, 10-14, 15-19, 20-24, 25-29 | |
under_tretti = sum(map(sum, a[:6])) | |
print(100 * under_tretti / totalt) |
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
# To make a long story short | |
# Install apt source | |
curl -fsSL https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB | sudo gpg --dearmor --output /usr/share/keyrings/intel-sw-products.gpg | |
echo "deb [signed-by=/usr/share/keyrings/intel-sw-products.gpg] https://apt.repos.intel.com/oneapi all main" | sudo tee /etc/apt/sources.list.d/intel-oneapi.list | |
apt update | |
# Install oneapi | |
apt install intel-oneapi-runtime-opencl intel-basekit clinfo opencl-headers |
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
import numpy as np | |
def fib(n): | |
"""Fibonacci using matrix exponentiation""" | |
m = np.array([[1, 1], [1, 0]]) | |
pow_m = np.linalg.matrix_power(m, n) | |
return pow_m[0, 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
123456 | |
123456789 | |
qwerty | |
password | |
12345678 | |
111111 | |
qwerty123 | |
1q2w3e | |
1234567 | |
abc123 |
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
#!/usr/bin/env python | |
import random | |
things = [ 'chips', 'husdjur', 'demoner', 'jesus', 'popcorn', 'bullar', 'saft', 'ärtor', 'pengar', 'godis', 'kaffe', 'te', 'kebab', 'pizza', 'paket', 'mamma', 'tandkräm', 'gröt', 'AK47', 'proteinshake', 'ägg', 'pannkakor', 'fiskbullar', 'köttbullar', 'spaghetti', 'nudlar', 'flingor', 'apelsinjuice', 'ostmackor', 'havregryn', 'strumpor', 'byxor', 'solrosfrön', 'senap', 'ketchup', 'små rymdgubbar', 'tomtenissar', 'ostbågar', 'rostad majs', 'lillasyster', 'citronbitare', 'fiskpinnar', 'knäckebröd', 'julmust' ] | |
places = [ 'på spisen', 'i ugnen', 'i torkskåpet', 'under sängen', 'bakom soffan', 'på dagis', 'hos rektorn', 'i himlen', 'i hallen', 'i kyrkan', 'i fotöljen', 'i gondolen', 'i Sherwoodskogen', 'i kaffekoppen', 'i blodomloppet', 'i magen', 'i flaskan', 'i badrumsskåpet', 'i toaletten', 'på nätet', 'på toasitsen', 'på golvet', 'på vinden', 'på taket', 'på stolen', 'på hatthyllan', 'på varmvattenpumpen', 'på bänken', 'på båten', 'på steam', 'på ICA', 'på netflix', 'på s |
NewerOlder