Skip to content
View criteria.txt
Write a program that does what it’s supposed to do
Write idiomatic code
Debug a program that you wrote
Debug a program someone else wrote
Debug the interaction between a system you wrote and one you didn’t
File a good bug report
Modify a program you didn’t write
Test a program you wrote
Test a program you didn’t write
Learn a new programming language
View base_whatever_encoding.py
def base36encode(number, alphabet='23456789ABCDEFGHJKMNPQRSTUVWXYZ'):
"""Converts an integer to a base36 string."""
if not isinstance(number, (int, long)):
raise TypeError('number must be an integer')
base36 = ''
sign = ''
if number < 0:
sign = '-'
View Makefile
ts := `/bin/date "+%Y-%m-%d@%H:%M:%S"`
SOURCES=$(wildcard *.md)
OBJS = $(patsubst %.md, %.html, $(SOURCES))
BODYCLASS=default
BASE=$(HOME)/www.btbytes.com
BASEURL=https://www.btbytes.com/
TARGET=$(BASE)/_site
INC_BEFORE_FILE=$(BASE)/templates/topnav.html
View grub_puppy_iso.md

To boot directly from a Puppy linux Live CD using these instructions

Put this in /etc/grub.d/40_custom and run update-grub2.

menuentry "Puppy linux ISO" {
set isofile="/boot/april.iso" 
loopback loop (hd0,1)$isofile
linux (loop)/vmlinuz  iso-scan/filename=${isofile} quiet splash
initrd (loop)/initrd.q
View 0readme.md
View xmldemo.scala
Welcome to Scala version 2.11.7 (Java HotSpot(TM) 64-Bit Server VM, Java 1.8.0_45).
Type in expressions to have them evaluated.
Type :help for more information.
scala> import rapture.xml._
import rapture.xml._
scala> import xmlBackends.stdlib._
import xmlBackends.stdlib._
View jargon.md

Category theory jargon cheat sheet

A primer/refresher on the category theory concepts that most commonly crop up in conversations about Scala or FP. (Because it's embarassing when I forget this stuff!)

I'll be assuming Scalaz imports in code samples, and some of the code may be pseudo-Scala.

Functor

A functor is something that supports map.

View littlesquares.elm
import Color exposing (..)
import Graphics.Collage exposing (..)
import Graphics.Element exposing (..)
ltlsqr size color xmov ymov =
ngon 4 size
|> filled color
|> move (xmov,ymov)
View challenge.md

You got your hands on some data that was leaked from a social network and you want to help the poor people.

Luckily you know a government service to automatically block a list of credit cards.

The service is a little old school though and you have to upload a CSV file in the exact format. The upload fails if the CSV file contains invalid data.

The CSV files should have two columns, Name and Credit Card. Also, it must be named after the following pattern:

YYYYMMDD.csv.

View rnotes.md

To fix the problem -- Library not loaded: @rpath/libjvm.dylib

export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:/Library/Java/JavaVirtualMachines/jdk1.8.0_25.jdk/Contents/Home/jre/lib/server/
open -a Rstudio
Something went wrong with that request. Please try again.