Solution to #35.