Programming

The earliest memory I have of ‘programming’ is in the early/mid 90s when my father brought home a computer from work. We could play games on it … so of course I took the spreadsheet program he used (LOTUS 123, did I date myself with that?) and tried to modify it to print out a helpful message for him. It … halfway worked? At least I could undo it so he could get back to work…

After that, I picked up programming for real in QBASIC (I still have a few of those programs lying around), got my own (junky) Linux desktop from my cousin, tried to learn VBasic (without a Windows machine), and eventually made it to high school… In college, I studied computer science and mathematics, mostly programming in Java/.NET, although with a bit of everything in the mix. A few of my oldest programming posts on this blog are from that time.

After that, on to grad school! Originally, I was going to study computational linguistics, but that fell through. Then programming languages (the school’s specialty). And finally I ended up studying censorship and computer security… before taking a hard turn into the private sector to follow my PhD advisor.

Since then, I’ve worked in the computer security space at a couple of different companies. Some don’t exist any more, some you’ve probably heard of. I still program for fun too, and not just in security.

But really, I still have a habit of doing a little bit of everything. Whatever seems interesting at the time!


All posts

Recent posts

AoC 2016 Day 8: Tiny Screen Simulator

Source: Two-Factor Authentication

Part 1: Implement a 50x6 pixel screen with the following commands:

  • rect AxB turn on a rectangle of pixels in the top left corner
  • rotate row y=A by B rotates row A right by B pixels
  • rotate column x=A by B rotates column A down by B pixels

After a given sequence of commands, how many pixels are on?

read more...


AoC 2016 Day 4: Room Validator

Source: Security Through Obscurity1

Part 1: A room is described as a name, a sector ID, and a checksum as follows:

aaaaa-bbb-z-y-x-123[abxyz]

name: aaaaa-bbb-z-y-x
sector ID: 123
checksum: abxyz

A room is valid if the checksum contains the five most common letters if the name (ties broken alphabetically).

read more...


AoC 2016 Day 2: Pin Typer

Source: Bathroom Security

Part 1: Take a keypad with the following layout:

1 2 3
4 5 6
7 8 9

Using the instructions UDLR for Up, Down, Left, and Right respectively, move a ‘finger’ around over the keypad. At the end of each line of instructions, output the current digit.

read more...


Solving Loop Puzzles

A quick puzzle from Daily Programmer:

∞ Loop is a mobile game that consists of nm tiles, placed in a nm grid. There are 16 different tiles:

┃, ━, ┏, ┓, ┛, ┗, ┣, ┳, ┫, ┻, ╋, ╹, ╺, ╻, ╸, ' '.

The objective is to create a closed loop: every pipe must have another tile facing it in the adjacent tile for example if some tile has a pipe going right, its adjacent tile to the right must have a pipe going left.

The most straightforward solution is a hybrid combination of constraints and backtracking, similar to what I did when solving Takuzu and tile puzzles.

read more...