Convert width and length to generic side length

Reviewers: eater

Reviewed By: eater

Differential Revision: http://phabricator.khanacademy.org/D9095