## Posted on Jan 23, 2015 Modular ZSH Configuration

I love the Z-Shell. I really do. It is so choice. And if you’re using just the basic bash or even sh, you’re missing out on some really cool features. (Note, I am talking about a shell for personal use, not on a server, where the zsh may not be the right choice.) If you’re using zsh but without some hand-picked customizations, you’re also missing out. In this post I am going to talk about my own setup for ZSH configuration, which you can easily adopt for yourself.

## Posted on Nov 14, 2014 Introduction to Haskell

Today I gave a presentation about my personal favorite programming language: Haskell. This is what I presented, which is also available in PDF format.

Before we get into how to actually build stuff in Haskell, you should have at least a basic understanding of what Haskell is, and how it differs from the programming languages you’re likely to already know.

Haskell is a lazy, purely functional programming language. This means a few things:

#### Laziness: Last-Minute Evaluation

One of the ways that Haskell improves the performance and expressiveness of code is through laziness. This means that nothing you write in Haskell is evaluated until it has to be. Let’s look at an example from GHCi, the Haskell interpreter:

> let x = 3 + 7
> x
10

You might think that the 3 + 7 expression is evaluated in the first line, but it’s not. In fact, evaluation doesn’t happen until the second line. The first line is instead a promise to evaluate x to that particular value when it’s needed. Until x is called for, the evaluation doesn’t happen, and if x is never called for, the evaluation never happens at all.

## Posted on Nov 13, 2014 5 Cool Things About Rust

I wrote this small essay for a presentation in my Senior Seminar class. I have reproduced it here (and made it available as a PDF) in case anyone is interested.

Rust is a safe systems language designed by Mozilla as an alternative to C and C++. It is already being used in the creation of large software systems, including its own compiler (rustc), and a web browser rendering engine called Servo.

Rust focuses on providing language features that guarantee the nonexistence of certain classes of common errors, without impairing program performance. Those errors include:

• Memory leaks
• Data races
• Buffer overflows
• Segmentation faults

These errors, and others like them, are common and easy to have in existing systems languages like C and C++. The conventional wisdom has long been that avoiding these errors will bring untenable performance penalties. Rust is proof that this isn’t true. Instead of adding runtime checks to avoid these problems, Rust uses a full-featured collection of compiler checks to verify they can’t happen, and then generates efficient machine code without any runtime checks.

In this small essay I will walk through a collection of five Rust features (Cargo, immutable-by-default variables, traits, the borrow checker, and pattern matching) that make creating systems in Rust a joy. They are not the only selling points for Rust, but they should provide a nice introduction to some of the wonderful things that Rust provides, and should hopefully convince you to try it out. If you want to know more, check out http://rust-lang.org.

## Posted on Nov 1, 2014 Room for Squares (Dodecahedrons Too)

I’ve been playing Pathfinder with a group led by my friend Anthony for several weeks now. Today our characters (myself a Kitsune Trickster, along with a Half-Elf Druid, an Ifrit Brawler, an Undine Swashbuckler, and a Sylph Arcanist) found ourselves in the home of the Wizard’s Guild of the city of Promise (a silly name invented in a previous campaign). Concerned with the disappearance of their two shock lizard mascots, they sent us quickly to the unexplored chambers of their departed leader. We were told to retrieve the lizards, and if possible figure out how to navigate this part of the guild’s home.

We quickly encountered a problem. The first room found us exiting a door embedded in a pillar that sat in its center. Walking around the pillar we found that the seemingly square room had five sides (although at every point the walls met at right angles). Realizing that there was some non-Euclidean silliness about, I quickly began a map of the rooms as we traveled through them.

## Posted on Jun 24, 2014 Computing and Computers

There was an interesting belief several decades ago, most prominently held by Edsger Dijkstra, that computing as a field could be separated entirely from computers, the machines that engage in computing. The argument went something like this:

1. The theorems of computing are true regardless of the machine they are implemented on. Put another way, the only machines to be called computers were those machines that could engage in computing, and any such machine is equivalent to any other, save for implementation details
2. Algorithms, the formal method for defining computation, exist independently of the machines that implement them
3. Limitations on computation are not truly given by hardware (if they, the limitation is temporal, not technical, in nature) but by the algorithm itself

In other words, while algorithms are not useful unless they have a machine to implement them, the truth of what they are and can do exists independently of such a machine. Thus, the conflation of program and machine, of computing and computer, is wrong.

## Posted on Jun 23, 2014 Write Like A Person

I’d like to take a moment to speak to all the students who have just in the last month or so graduated from High School, and who are now preparing to join the workforce or go to university. I’d like to share with you a piece of advice I wish I’d received. Something that took me years to realize independently. It’s about writing. It’s about how to write well and not sound like a jackass; and I never figured it out until I went back and read some of the things I’d written in the past. It’s something that will require a lot of you to forget what you learned in High School: forget the five paragraph format, the hook-thesis-preview opener, the summative conclusion, all of it. It may seem intimidating at first, and so in this small piece I will spend the majority of my time explaining why this is in fact easier for you than everything you’ve learned, and I will attempt to convince you that writing in this way will not only make it easier to write, but will improve people’s reactions to what you’ve written. So what is this suggestion?

Write like a person.

## Posted on Jun 21, 2014 Is This Really Permanent?

Ars Technica has an article out about preserving technology. Read it if you haven’t already. It’s not long, and the topic is important.

I liked the article, in case it wasn’t clear, and it got me thinking about the issue of information permanence. In the past our knowledge and experiences (or at least artifacts that act as evidence of them) were inherently preserved to some degree by their medium of expression. Pictures were physical goods, books were physical goods, videos were physical goods. Yet the increasing digitization of human experience makes that experience all the more fragile to the whims of time. Imagine for a moment what would happen if Dropbox disappeared, so that all your data stored there was gone forever. Would you still have your pictures? Would you still have your videos? Your essays? What would remain to you? Maybe you backed it all up and it’s on a hard drive somewhere. Well, imagine it’s 50 years later, and you’ve found that hard drive and you want to take a look and those old pictures and videos. Can you even use it? Do you have a device that can connect to it and read it? Or was the permanence of the physical good a lie?

## Posted on Jun 17, 2014 Surpassing The Hacks

Web development history is rife with hacks. Developers have always been looking to push the boundaries while maintaining relative consistency cross-browser, and the pace of developer creativity has consistently exceeded the pace of implementer development. So, hacks.

## Posted on May 26, 2014 Goodbye Quora

I have recently decided, after much consideration and an abundance of time, to leave Quora behind. I have been an active member for several years, and have shared information on there across topics as diverse as Computer Science, the proper use of Tumblr, and elementary school bullying. In that time I have interacted with a number of impressively funny and intelligent individuals, and I am happy to say I have learned a lot about a variety of subjects.

Why then, have I chosen to leave?

## Posted on May 25, 2014 Dijkstra’s Writings Available

Edsger Dijkstra, famous Computer Scientist, is one of my favorite intellectuals. He was a man with strong opinions, who consistently and publicly defended them. His piece “On the Cruelty of Really Teaching Computer Science” stands as one of my favorite pieces of academic writing.

## Posted on Feb 24, 2014 Getting Back

I returned just yesterday from the Southern California Linux Expo. It was my first time going, and I went with a large group of friends, all of whom but one had also never been. It was a fun time. This post isn’t about the conference though. It’s about what happens when you get back.

Conferences and expos are a time to extract yourself from the world, and have some fun learning new things and meeting new people. There’s a certain joy in the picking of sessions and watching of keynotes. A certain excitement in a conversation picked up with strangers over some tech overhead in passing.

Senior at CSU, San Bernardino majoring in Computer Science with a Minor in Math. Interested in formal languages, logic, type theory, and programming language design.