Skip to content

Instantly share code, notes, and snippets.

View dakerfp's full-sized avatar

Daker Fernandes Pinheiro dakerfp

View GitHub Profile
@dakerfp
dakerfp / robot.js
Created December 4, 2012 01:17
halfling
var IDLE = 0;
var SCANNED = 1;
//FightCode can only understand your robot
//if its class is called Robot
var Robot = function(robot) {
this.state = IDLE;
};
This file has been truncated, but you can view the full file.
*** Cleaning fonts *** [1/1](B
]0;jhbuild:Cleaning fonts [1/1]make -j 16 clean
*** success *** [1/1](B
]0;jhbuild:success [1/1]Updating EFL port dependencies using jhbuild...
Fetching origin
gnome-autogen.sh not available
gnome-doc-tool not available
Configuring jhbuild without autotools
Now type `make' to compile jhbuild
make[1]: Entering directory `/home/dakerfp/work/WebKitBuild.nix/Dependencies/Source/jhbuild/po'
@dakerfp
dakerfp / zero.go
Created June 16, 2017 00:16
Utility to pad a writer with zeros
package zero
import (
"io"
)
type ZeroPad struct {
w io.WriteCloser
nleft int
}
# Mold #50 - Wizard Tower
# Mold #55 - Bell tower
# Mold #65 - Ruined tower
# Mold #60 - Prison tower
# Mold #63 - Octagon Tower
# Mold #226 - Wooden Beam
# #245 - Slate Shingle Roof
# #259 - Rubble Bridge
import math
# Mold #50 - Wizard Tower
# Mold #55 - Bell tower
# Mold #65 - Ruined tower
# Mold #60 - Prison tower
# Mold #63 - Octagon Tower
# Mold #226 - Wooden Beam
# #245 - Slate Shingle Roof
# #259 - Rubble Bridge
import math
import math
def inches_to_cm(inches):
return inches * 2.54
def feet_to_inches(ft):
return 12 * ft
def perimeter(w, h):
return 2 * w + 2 * h
from enum import Enum
from random import randint
class Weather(Enum):
CLEAR = auto()
CLOUDY = auto()
RAINY = auto()
def next(self):
d6 = randint(1,6)
import requests
from bs4 import BeautifulSoup
import re
from bs4.element import ContentMetaAttributeValue
def trim(s):
return s.strip().replace('\n', '')
class Color(object):
// https://orteil.dashnet.org/cookieclicker/
var cookie = document.getElementById("bigCookie")
var cookieIntervalId = setInterval(function() {
cookie.click();
}, 100);
#include <stack>
#include <cassert>
using namespace std;
namespace hanoi {
static void move(stack<int>& from, stack<int>& to)
{