Category: misc
FEB 28 2013
Building Stripe's API
Last week, I gave my first conference talk at the [API Strategy and Practice] conference in New York. Pretty exciting! I thought it would be interesting to talk about [Stripe]'s API, particularly lessons learned and what kind of things we did to try to make the API as easy to...
DEC 21 2012
Private methods in Ruby
Consider the following code: (This blew my mind the other day.) class Hello def public_hello self.private_hello end private def private_hello puts "Hello!" end end You would expect that this would work fine: `private_hello` is a private method, but it's being called from within the class. Nope. >> hello = Hello.new...
OCT 31 2012
Discount Code Cards
I love career fairs. In college, I loved going to career fairs to get swag—EECS majors are definitely ridiculously spoiled when it comes to getting free things like shirts and food (I even got a poker set once!). Anyway, while planning our trip to the [UC Berkeley Startup Fair](http://ucbstartupfair.com) this...
JUN 18 2011
Exporting SVN to Git
I love Git. So much, in fact, that when I switched web hosts last month I decided to move all of my SVN repositories and put them on [Github](https://github.com/afeng) or into private Git repositories. Github's SVN import utility is painfully slow (and maybe even broken, I'm not sure) - so...
DEC 24 2010
My Launch Checklist
Before you think about launching a site, make sure you have your bases covered! Here are the top three things I always have on my "checklist". ## Cross-browser Compatibility This seems like a no-brainer, but I'm usually pretty bad with this because I like to test and debug all of...
SEP 14 2010
Fibonacci Times Three
On the first day of my Algorithms class here at school, we learned three ways to implement the well known [Fibonacci series](http://en.wikipedia.org/wiki/Fibonacci_number) generating algorithm. ## Standard recursive Everyone and their mom knows the recursive way to implement Fibonacci: def fib(n) return 1 if n < 2 fib(n-1) + fib(n-2) end...
AUG 20 2010
Google Code Jam: Alien Numbers
Lately I've been really into doing Google Codejam practice problems (aka I'm a nerd). I discovered I really need to brush up on my algorithms ): ## The Problem The decimal numeral system is composed of ten digits, which we represent as "0123456789" (the digits in a system are written...
JUL 14 2010
SVN Ignoring Files/Directories
I've been trying to learn more about using command line SVN because I'm not terribly familiar with it, here is a super quick reference guide to the most common/useful SVN commands. ###Checking out a repository (with optional username/password flags): svn checkout [SVN REPO] [LOCAL DIR] --username [USER] --password [PASS] ###Copying...
JUL 14 2010
Automatically Capturing Website Screenshots
I've recently had inspiration for a new web application that fits my needs as a web designer (it's a secret for now), but it's not a standard CRUD web app so it requires a fair amount of new programming/customization that I'm struggling with. One thing the application requires that I'm...
JUL 01 2010