Homework for CS450, it could be useful later on if I want to process images using Java.