- 50.9k
- 11
- 133
- 364
Husk, 11 bytes
I got ninja'd..
§&tΛo€Ṗd1dp
Outputs truthy for a lobster number and falsy otherwise. This would be shorter if all returned 0 for empty lists.
Explanation
§&tΛo€Ṗd1dp
p prime factorization of the input
§ fork:
t is the list not composed of a single element?
& and,
Λo d are all the prime factors' digits
€ present in
Ṗd1 the powerset of the input's digits?
Husk, 11 bytes
I got ninja'd..
§&tΛo€Ṗd1dp
Outputs truthy for a lobster number and falsy otherwise. This would be shorter if all returned 0 for empty lists.
Explanation
§&tΛo€Ṗd1dp
p prime factorization of the input
§ fork:
t is the list not composed of a single element?
& and,
Λo d are all the prime factors' digits
€ present in
Ṗd1 the powerset of the input's digits?
Husk, 11 bytes
I got ninja'd..
§&tΛo€Ṗd1dp
Outputs truthy for a lobster number and falsy otherwise. This would be shorter if all returned 0 for empty lists.
Explanation
§&tΛo€Ṗd1dp
p prime factorization of the input
§ fork:
t is the list not composed of a single element?
& and,
Λo d are all the prime factors' digits
€ present in
Ṗd1 the powerset of the input's digits?
Husk, 11 bytes
I got ninja'd..
§&tΛo€Ṗd1dp
Outputs truthy for a lobster number and falsy otherwise. This would be shorter if all returned 0 for empty lists.
Explanation
§&tΛo€Ṗd1dp
p prime factorization of the input
§ fork:
t is the list not composed of a single element?
& and,
Λo d are all the prime factors' digits
€ present in
Ṗd1 the powerset of the input's digits?
Husk, 11 bytes
§&tΛo€Ṗd1dp
Outputs truthy for a lobster number and falsy otherwise. This would be shorter if all returned 0 for empty lists.
Explanation
§&tΛo€Ṗd1dp
p prime factorization of the input
§ fork:
t is the list not composed of a single element?
& and,
Λo d are all the prime factors' digits
€ present in
Ṗd1 the powerset of the input's digits?
Husk, 11 bytes
I got ninja'd..
§&tΛo€Ṗd1dp
Outputs truthy for a lobster number and falsy otherwise. This would be shorter if all returned 0 for empty lists.
Explanation
§&tΛo€Ṗd1dp
p prime factorization of the input
§ fork:
t is the list not composed of a single element?
& and,
Λo d are all the prime factors' digits
€ present in
Ṗd1 the powerset of the input's digits?
Husk, 11 bytes
§&tΛo€Ṗd1dp
Outputs truthy for a lobster number and falsy otherwise. This would be shorter if all returned 0 for empty lists.
Explanation
§&tΛo€Ṗd1dp
p prime factorization of the input
§ fork:
t is the list not composed of a single element?
& and,
Λo d are all the prime factors' digits
€ present in
Ṗd1 the powerset of the input's digits?