Skip to content

Instantly share code, notes, and snippets.

View dhedegaard's full-sized avatar

Dennis Hedegaard dhedegaard

View GitHub Profile
@dhedegaard
dhedegaard / apex bite
Last active December 22, 2020 21:18
weak auras
!WA:2!fwvZYnXrqyRiijShi2IFm4abfOIHajoGbCLFjrRrcReHK8UlyiLtjp7UT0oXR3zyMzTS9PGoKIZ6rqhYPuvQspbu(jykvPYPKl(rWpbzMzLmqUKlZ2tpDpD3t)1FBUhxG7C7fU1c3PWwfcle(IloYhfSziJqxMetyFF(85BM)MlC3d8jSqGzp(q602X492dXcl6riXcmDGGeSnW4ysY5Y1QpBNgTBZbro)mhJy7owXag0rzK3UuWPdJKshKzHlEp44dZKZIDUC5Y7WdqXqE)assBChlgkqOCMVKdxGycl)24empYYw9ry1tWWD6OsI5MNnw8xhec(PTBRdhBLY1Aw5r1Sf6yJszOf7XPqCC1qU1b8uFyBir4QSgVZWwlxY1RLRxjhp7u1L7tJr7cmNe0wa3YXyQ)kakweDKRnzGYvh3MLRvRFAY4uWACbwoSdqNX9zPiguSsACCX1IWc4qCIayjO4hN96T6qusqeH1KOoWF5Y19k70hLG3cPR8LKtxzFaXbxbds6iIEh5S2jKeyuOQE0w0sxDmoOEXc590MQRD5nS3cHtQiVUYb5nKFI8tLlO(oZ)vZLXH9lrHDkARYTH4K2ewwKTg2MPQDvCrcu(dZsYkAv6733DzNYLRpcLkuQBqnDjRXTZQjQgF(9Z2KbdoXa1JMJbjWT6ZH42M6vETb68gN5UDmbfUKTQhfCwNTsvWmlNGyeNFw53yzZvagTWIP4WH)Wn3dAdlXRSKBHG5EXvgGv3JljLfaxyk5BVYlF2X)JFzQPMs(UR8YF6F(BJ4vLxBuGc9gs6M42ftHn2FYwDVkYwFhBip1jNxE6FJLYH6QIDJ(AGJbfmhDwZlLQThIee2v5fxMH2gN0rEjzr5hkVS88wY5KVV8cYlk)al1Z85KNrEw5vSOZObYBdEzqKhscHFFk58RE4MaqlPlyHJ(vps(fQNKqGJe62lej)8R)IttliGDeT4rivU(KXZv0ZBuAwYAAT4JfK3O)rND5pItN(1C)vJAhKPDsRW
@dhedegaard
dhedegaard / deedees.user.js
Last active June 24, 2020 06:30
Simplifies Dee dee's ordering via URLs
// How to use:
//
// 1. Install the TamperMonkey Chrome extension.
// 2. Click on the extension in the address bar and go to "Dashboard".
// 3. Inside the extension, go to "Utilities" and "Install from URL":
// <https://gist.github.com/dhedegaard/7d59e19dc1a0a67db1f55c236090a17f/raw/deedees.user.js>
// 4. Tampermonkey will not show you the script, feel free to read through it and click "Install".
// 5. Go to deedees.dk, find a product and change the choices for the product.
// 6. You will now see that the URL has some GET parameters in it.
//
@dhedegaard
dhedegaard / hqwrapper.go
Last active January 6, 2016 20:18
hqwrapper.go
package main
import (
"fmt"
"io"
"net/http"
"github.com/gin-gonic/gin"
)
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Drawing.Imaging;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading.Tasks;
using System.Timers;
from __future__ import absolute_import, division
from copy import deepcopy
from cStringIO import StringIO
def solve(board):
'''
Returns a solved version of the board, if it is solvable.
:param board: The board to solve, as a list of lists, of integers from
<!DOCTYPE html>
<html lang="en">
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css">
<title>PoE XP Calculator</title>
<style rel="stylesheet">
.hidden {
display: none;
}
@dhedegaard
dhedegaard / euler72.sql
Last active December 30, 2015 23:18
euler72
-- Euler 72 - implemented as a postgresql 9.x function.
-- A very brute forceish approach to see how psql handles lots of data
-- in a temporary table while doing lots of calculations.
drop function if exists gcd(integer, integer);
drop function if exists euler72(integer);
create function gcd (a integer, b integer) returns integer as $$
begin
while a <> b loop
if a > b then
@dhedegaard
dhedegaard / double-checker.py
Last active December 24, 2015 08:09
double-checker.py
#!/usr/local/bin/env python
# -*- coding: utf-8 -*-
import os
import glob
import hashlib
import Tkinter as tk
import win32api
>>> sum([int(e) for e in str(2**1000)])
1366