exercism / problem-specifications

Shared metadata for exercism exercises.
MIT License
327 stars 543 forks source link

[perfect-numbers] Description is not clear #447

Closed snahor closed 7 years ago

snahor commented 7 years ago

The description isn't very clear, I mean it's not clear what to implement. I've been looking at the implementations and there's no consensus. Some of them implement the classification and the others just check whether or not the number is perfect.

Insti commented 7 years ago

Perfect numbers description

Insti commented 7 years ago

I would suggest doing something like what we have recently done for triangles. Triangles test data

Where there are 3 different functions that return a boolean value depending on if the number is Perfect, Deficient, or Abundant

guntbert commented 7 years ago

Looking at Triangles I see that metadata.md contains a clear statement what to do

Write a program that can tell you if a triangle is equilateral, isosceles, or scalene.

This statement is missing here.

guntbert commented 7 years ago

@Insti this might be a good "first patch"

petertseng commented 7 years ago

Naturally, one might ask: Is #481 sufficient to close this issue?

It certainly has helped greatly in this regard.

I think a little help in the README would be good - so perhaps https://github.com/exercism/x-common/blob/master/exercises/perfect-numbers/description.md could also say that we need to be able to determine whether a given number is perfect, abundant, deficient.

The sentence on the Aliquot sum also seems a bit out of place.

petertseng commented 7 years ago

perhaps https://github.com/exercism/x-common/blob/master/exercises/perfect-numbers/description.md could also say that we need to be able to determine whether a given number is perfect, abundant, deficient.

518 takes care of that.