Revert "break up longer function and add guard clauses"
Revert "break up longer function and add guard clauses"

This reverts commit 8b5b4ea19b0d5187e17797aa643a209a587314e4.

googleinterns/spec-math,googleinterns/spec-math,googleinterns/spec-math,googleinterns/spec-math