There was a (possible) mistake in one of the test-cases.
Namely, for sides [3,3,2] I got [39, 71, 71], which has a total of 181. I mean, we really do use rounding and all that, but shouldn't the result satisfy the necessary angle sum condition?

Created at: 2013/08/26 23:02; Updated at: 2013/11/24 21:38