forked from M3-Academy/challenge-algorithms-v2.0
Merge branch 'feature/05-isPrime' into developer
This commit is contained in:
commit
ff2afec8ab
@ -1,4 +1,9 @@
|
||||
export function isPrime(value) {
|
||||
// implementar logica aqui
|
||||
|
||||
for (let index = 2; index < value; index++) {
|
||||
if (value % index === 0) {
|
||||
return false
|
||||
}
|
||||
}
|
||||
return value > 1;
|
||||
}
|
Loading…
Reference in New Issue
Block a user