Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
I don't understand the maths (as in why the angles add up the way they do), so I googled it, which just gave me the answer. I understand the calculation in terms of the output of the code, but I clearly do not understand how polygon angles work. I'm not sure that this would come up outside of an exercise trying to teach the maths though.
Fixed
Tests generate 0, 1, and 2, and the solution makes negative values.
Also, the actual and expected are reversed, but apparently you figured that out.
I'll fix this.
@rowcased: You don't have to ask that every time, check one's profile first (if multiple languages, then if they've completed it like in this case, you can find the language under their solutions).
Java.(both answered at the same time)Java language. I had to try a few times until it passed on the atempts, because sometimes i was having these expectations on the tests.
to which language are you referring?
whats up with the random tests expecting 0, -180 and -360, sometimes?
Now?
It should say "internal angles" as Unnamed suggested.
Also there's a mistake in "n-sided", and I don't think it makes much sense to say "total sum", but that's not a big deal.
Fixed?
It should be internal angles, simple polygon. It doesn't have to be convex, but at the same time a regular polygon can be a star.
This is a classic math problem, and it requires no additional explanation.
The description should mention that the polygon is regular.
Loading more items...