Ali Malik
Student and Lecturer at Stanford University
malikali _at_

I am a student at Stanford University studying Mathematics (logic and analytic number theory) and Computer Science (theory and systems/network security). I lecture a class on standard C++ programming!

I love teaching and thinking about problems that make my brain hurt. I keep a blog on the side where I write about random Maths, CS, and Philosophy related gems that come my way.

Archive of Code

This is a compilation of various code snippets and programs I have written over the years. Examples include some interesting data structures, algorithms, interview problems, as well as other utility functions that I've found use for from time to time.

Particle Simulator

An event based particle simulator wrtitten in standard C++. Relies on Qt libraries for graphics.

Algorithm idea taken from Algorithms by Robert Sedgewick and Kevin Wayne.


An implementation of cosine-similarity based authorship identification written in standard C++. Example here used to identify who wrote a given unkown Federalist paper.

Snake Bot

A simple ASCII snake player written in C++. Idea from Keith Schwarz's CS106L course reader.

Smart Pointers

A really basic C++ implementation of Shared and Unique ptr.