perfect number using immutable-js