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.
Enabled in this fork
Description should be language agnostic. Here is a suggestion for a fix (reworded).
preview
Task
Write a function that returns the power of
2
in the prime factorization of a positive integer (>= 1
).Examples
copy-paste
# Task
Write a function that returns the power of `2` in the prime factorization of a positive integer (`>= 1`).
# Examples
```
24 should return 3 -> 24 = 23 * 3
17280 should return 7 -> 17280 = 27 * 3**3 * 5
```
Lua translation !
Haskell translation
The proper name for 'relatively prime numbers' is 'coprime numbers', so you can change the title if you want ;)
This kata is not about primes but about "relatively prime". Where do you read anything about 1 considered a prime in this kata? Description only talks about factors and divisors.
One cannot be called a prime number, since a prime has 2 divisors, and one is 1. The number 1 is not classified as either simple or composite
Here 1 is considered a prime number
Superceded by latest fork
Approved
Lua translation!
Node 18 for JS
Python new test framework
First, there is a typo in the desription. "All numbers in will be positive integers.". I guess the word "arr" is missing in there.
Second, the description create unnecessary confusion. At the beginning a range of numbers are compared to each other. But afterwards a list of number shall only be compared to one number (=n).
Loading more items...